querying many-2-many relations with cross reference table.

querying many-2-many relations with cross reference table.

Postby yuri@wallie.com » Wed 18 Feb 2009 15:57

Hi Forum,

I've read that it was possible to use LINQ query's to query data from cross reference tables without having to reference the crosstable itself in the linq query. Here is an example:

Table1: Employees
PK: employeeid

Table2: Cross reference between Employees and Roles
FK: employeeid
FK: roleid

PK roleid


i would like to query something like

var employees = from e in db.employees.where(e => e.employees.roles.rolename.contains(xxx)..

But i cannot make this work, does anyone has any tips ?

Thanks in advance,

Posts: 27
Joined: Mon 08 Sep 2008 16:37

Postby AndreyR » Tue 24 Feb 2009 11:32

This scenario is not supported yet. We plan to support it, but no timeframe can be provided.
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Return to LinqConnect (LINQ to SQL support)