Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6869907
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T03:37:00+00:00 2026-05-27T03:37:00+00:00

Hi i need suggestion to do this in linq. need to select all rows

  • 0

Hi i need suggestion to do this in linq. need to select all rows which are IsAvail = true and get 5 first rows. i done the following query

from i in entity.Bills.OrderBy(e => e.From).Skip(CurrentPage).Take(intRecordsPerPage)
join c in entity.Cust on i.Id equals c.Id into c_join
from c in c_join.DefaultIfEmpty()
where i.IsAvail == true
select new { i, Id = c.Id };

But when the IsAvail is true in 6th recored i cant get it in first page.
i can get in second page only, first page remains blank.
how can i solve this

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T03:37:01+00:00Added an answer on May 27, 2026 at 3:37 am

    Simply put the Skip/Take at the end of the query:

    var allRecords = from i in entity.Bills
                     where i.IsAvail
                     orderby i.From
                     join c in entity.Cust on i.Id equals c.Id into c_join
                     from c in c_join.DefaultIfEmpty()
                     select new { i, Id = c.Id };
    
    var page = allRecords.Skip(CurrentPage).Take(intRecordsPerPage);
    

    (I’ve also put the where clause earlier and used query expressions for the whole thing, just for tidiness.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Locally I need to code against Java 1.4. I tried the suggestion in this
I need suggestion about YAMI library . I have a system which receives Json
I need select all elements from a set whose Id property is contained within
I'm having issues with a Linq query that will actually do what I need
This is a quick one. In Linq to sql, I need to order by
On a LINQ-result you like this: var result = from x in Items select
Given the following table structure, how can I use a Linq query to return
I need some suggestion on how to work this around. I have an Ajax
I'm just looking for suggestions on the best way to do this... I need
I know my question isn't about programming problem, I just need a suggestion to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.