I need to write on linq2sql analogue of the following query:
SELECT A.Field1, B.Field2 FROM tableA A, tableB B
How can I do that?
I would start from something like this
from a in DBContext.tableA,
...
select new {Field1=a.Field1, Field2=b.Field2};
but what should I write instead of "..."? How to mention 2nd table to be linked?
Thanks.
P.S. Hope I am clear
To cross join, try
from a in DBContext.tableA
from b in DBContext.tableB
select new {Field1=a.Field1, Field2=b.Field2};