>>What did select * from cteRanges order by DateCol DESC return? Did you list rows in the opposite order of the date? If yes, then the query I wrote from the top of my head should work. If you provide a quick test scenario with create table and insert rows statements, I would be able to test it.
>
>This is getting too complex. We will simply execute the initial select two or three times and this will do it.
Nothing is complex here. Check this page for better understanding of my idea:
http://pratchev.blogspot.com/2010/02/refactoring-ranges.html
If it's not broken, fix it until it is.
My Blog