StudentId StartDate EndDate
1 1/1/2013 31/12/2013
1 1/1/2014 31/12/2014
2 1/1/2013 1/11/2013
2 1/1/2015 31/12/2015
My LIST contains sample date like above.Here student "1" continued next year also,
In this case i want to show one record for him like below.
Here student 2 is discontinued so in this case i want to show two records also.
Finally i want to show the output like below .How Can i do this using LINQ query ?
StudentId StartDate EndDate
1 1/1/2013 31/12/2014
2 1/1/2013 1/11/2013
2 1/1/2015 31/12/2015
LINQ Dates Overlapping logic
3 Answers
Know the answer? Post it. Somebody with the same question will find it here.

ramya bharathRank #3,780 · 391 reputationPosted May 11, 2015, 10:25 AM EDT
Lawrence P4 reputationPosted Sep 9, 2015, 8:11 PM EDT
ramya bharathRank #3,780 · 391 reputationPosted Sep 10, 2015, 12:25 AM EDT
https://msdn.microsoft.com/en-us/library/bb546163.aspx