when i define a Complex Type (e.g. "testtc ) with Properties string "one", string "two", string "three") and put it in an Entity (e.g. "TestEntity") with an Id Property and generate the model class the complex type is generated as a Class testtc in class Testentity.
After generating a migration with dotnet ef migrations add XXX and dotnet ef update database the oracle table "testenty" has the id, one, two, three columns. All right... thats nice! the properties of the complextyp are handled like normal columns in the entittest table.
But when i try to retrieve data from the table with linq i must type
Code: Select all
var res = from myqry in testentity where myqry.testtc.one == "Hello" select xxxx...
I think the complextyp class should not be generated as a class testtc in testentity. It would be better if the properties of the complextypes were generated as properties in the entitytest class. apart from the error that occurs this is easier to handle when writing the linq.
can u tell me how to do that or correct it?
Thomas