• Naomi N (11/30/2011)


    How will you expand the solution when you have StartDate EndDate fields in your table and you want continuous intervals, e.g.

    01/01/2010 - 01/15/2010

    01/16/2010 - 02/10/2010

    The above two intervals should come as

    01/01/2010 - 02/10/2010

    I've never seen a blog explaining this more complicated case, although I have seen and tried myself to solve this problem.

    Naomi you'll want to start a separate thread to discuss this, but the trick is to use a Tally/Calendar table to fill/generate the dates between the two dates...it's a closely related idea to the Tally Splitting functionality.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!