I am currently using OData V4 and wish to join 2 tables Account and Product:
The tables are as follows: Account: Id, Name, Address, ColorCode,
Product: Id, AccountId
AccountId in the Product table is a foreign key mapped to the Id field in the Account table
In my builder I have :
var ProductType= builder.EntityType<Product>();
When I build the Product entity I wish to get the "ColorCode" values from the Account entity.
How can i establish this relationship in the model builder?
I would like the product class to look like this:
public class Product
{
public string Id { get; set; }
public string AccountId { get; set; }
public string ColorCode { get; set; }
}