Hi,
our Dev tools .Net, C# and MySQL community server 8.0.26. Project using MySql.Data as data driver and MySql.Data.EntityFramework for EF.
Trying fetch related tables via LINQ to Entities as below
..
Find(predicate)
.Include(o => o.EntityA.ChildEntityB)
.Include(o => o.EntityA.ChildEntityc)
.Include(o => o.EntityX)
.Include(o => o.EntityY)
.Include(o => o.EntityZ)
EntityA has relation(1:m) to two child Entities ChildEndityB and ChildEndityC.
Above query as is returning error, "Unknown column 'Join7.OrderId' in 'on clause'". When i looked at the SQL generated, it is trying access Select alias "Join7" where it is out of scope.
If comment out either ".Include(o => o.EntityA.ChildEntityB)" or ".Include(o => o.EntityA.ChildEntityc)" Include statment, then the query works fine.
Please advise or do let me know if you need any more information.
Thanks in advance
our Dev tools .Net, C# and MySQL community server 8.0.26. Project using MySql.Data as data driver and MySql.Data.EntityFramework for EF.
Trying fetch related tables via LINQ to Entities as below
..
Find(predicate)
.Include(o => o.EntityA.ChildEntityB)
.Include(o => o.EntityA.ChildEntityc)
.Include(o => o.EntityX)
.Include(o => o.EntityY)
.Include(o => o.EntityZ)
EntityA has relation(1:m) to two child Entities ChildEndityB and ChildEndityC.
Above query as is returning error, "Unknown column 'Join7.OrderId' in 'on clause'". When i looked at the SQL generated, it is trying access Select alias "Join7" where it is out of scope.
If comment out either ".Include(o => o.EntityA.ChildEntityB)" or ".Include(o => o.EntityA.ChildEntityc)" Include statment, then the query works fine.
Please advise or do let me know if you need any more information.
Thanks in advance