Hello friends,
I am beginner for Linq to Sql, I have one Query.
How to select 20 or 30 records from the database.
Thanks in advance.
Query related linq
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Gaurish Kumar108 reputationPosted Oct 5, 2009, 9:44 PM EDT
If you want to select the 20 records, u can use the Take keyword for that for ex:
(from p in dataContext.Customers
select p).Take(20)
I think it will solve your problem.
Sanjay Chauhan55 reputationPosted Oct 5, 2009, 9:58 PM EDT
It works!!
This forum is really very use full .