I would like to map an object, containing an aggregated instance of another object, to a single table.
I have two POCOs like:
[Table(Name = "TheTable")]
class A
{
[Column(Name = "PropA"), NotNull]
public string PropA { get; set; }
public B TheOtherObject { get; set; }
}
class B
{
public string PropB { get; set; }
}
I would like to map this, without repeating all the properties of class B in class A just for the purpose of mapping.
| ID | PropA | PropB |
Is there any way to achieve this with linq2db?
I'm using an MySQL database.