Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
2
Reply
c# Linq Take Selected Records
David Smith
Oct 26 2017 5:46 PM
207
Reply
I need to loop to each table getting or taking 2 records at time until all tables have been iterated through or empty. So I want to use Linq to do this. I am assuming a while loop is needed overall instead of a foreach. The logic should go
-Take 2 records, do something, then proceed to next table,
-take 2 records do something, then proceed to next table.
-Once you have reach the last table, go back to the beginning of the collection of the tables and repeat the process. We cannot exit the loop until all tables have process all records
Color Table 1:
ID | Item
1 | red
2 | blue
3 | green
Color Table 2:
ID | Item
1 | red
2 | blue
3 | green
4 | brown
Color Table 3:
ID | Item
1 | red
2 | blue
3 | green
4 | brown
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
2
)
Next Recommended Forum
subQuery using Linq
Linq Output Value