You have hit an unreported bug with our LINQ implementation. I am sorry for the inconvenience caused.
We have already started investigation for the cause of the issue and we will do our best to build a fix in our future releases.
Meanwhile you can use the following work-around (albeit it is less performant than the query you are expecting):
var query = from c
db.Products on c.CategoryId equals p.CategoryID into j1
db.Suppliers on c.CategoryName equals s.CompanyName into j2
where loj1 !=
|| loj2 !=
This query produces the following SQL statements:
SELECT DISTINCT a.[id] AS COL1
FROM [category] a
LEFT JOIN [product] AS b ON (a.[id] = b.[id2])
LEFT JOIN [supplier] AS c ON (a.[category_name] = c.[company_name])
WHERE (b.[id] IS NOT NULL OR c.[id] IS NOT NULL)
If this work around is not acceptable in your scenario, please let us know what your concerns are and if there are any additional restrictions that we are not aware of currently.
As recognition for reporting a new issue I am adding 500 Telerik points to your account.
I will let you know as soon as the fix for this issue is available publicly.
OpenAccess ORM Q2 2013 brings you a more powerful code generation and a unique Bulk Operations support with LINQ syntax. Check out the list of new functionality and improvements shipped with this release.