Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Apr 28, 2008 05:26 AM|LINK
I apologize for the non-working query. I created a test app, and I think the following will produce the result you desire:
I created two tables as follows:
CREATE DATABASE tstdb;
CREATE TABLE AppNames(ID int PRIMARY KEY, AppName varchar(50));
INSERT INTO AppNames
SELECT 1, "Excel"
SELECT 2, "Word"
SELECT 3, "Access"
SELECT 4, "ShadyApplication"
CREATE TABLE Applications(ID int PRIMARY KEY, AppNameID int REFERENCES AppNames(ID))
INSERT INTO Applications
SELECT 1, 1
SELECT 2, 1
SELECT 3, 2
SELECT 4, 3
If I run the Linq query without the where clause, I will get:
With the where clause:
AppName: Access; related apps: 1
AppName: Excel; related apps: 2
AppName: ShadyApplication; related apps: 0
AppName: Word; related apps: 1
Is that the behavior you were after?