Solved

I need help with a LINQ query in my ASP.Net application

Posted on 2011-09-14
2
204 Views
Last Modified: 2012-08-14

Hi experts
if I wanted to execute the query below using LINQ in my ASP.Net app with C# code behind, how would I do it in LINQ?  The query below is how I would execute it in SQL Server but how could I do this in LINQ?


SELECT
[School Year],
[Course Name]
FROM        
TBL_Course
where [CourseID] not in (select [CourseID] from TBL_Book where [BookID] NOT IN (14))



Thanks in advance,
mrotor
0
Comment
Question by:mainrotor
2 Comments
 
LVL 14

Accepted Solution

by:
nishant joshi earned 250 total points
ID: 36538191

[your linqtable or list] .where(!x=>x.[CourseID].exist([TBL_Book linq table].where(y=>y.bookid !=14)).select();
0
 
LVL 7

Assisted Solution

by:Kishan Zunjare
Kishan Zunjare earned 250 total points
ID: 36544616
0

Featured Post

How our DevOps Teams Maximize Uptime

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us. Read the use case whitepaper.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

SQL Server engine let you use a Windows account or a SQL Server account to connect to a SQL Server instance. This can be configured immediatly during the SQL Server installation or after in the Server Authentication section in the Server properties …
This article describes how to use the timestamp of existing data in a database to allow Tableau to calculate the prior work day instead of relying on case statements or if statements to calculate the days of the week.
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question