Home Forums SQL Server 7,2000 T-SQL Date Range between Start Date and EndDate RE: Date Range between Start Date and EndDate

  • armaandani (1/18/2013)


    thanks for your rply.

    Actually i am working in visual studion 2010 and SQL Express server 2008. i created my database through SQL Express server 2008.

    Now i have i have a table in which i have three coulmns.

    StartDate EndDate Class

    and i have an another table name as "DateTabe" which has also three coulmns

    Date Class Time

    i want that the date selected between StartDate and EndDate is made available in 'Date' coulmn which is in DateTable with class in 'class' coulmn.

    StartDateEndDateclass

    10/1/1213/1/12 A

    14/1/1217/1/12 B

    Then these can be show as in DateTable as

    Date class Time

    10/1/12 A

    11/1/12 A

    12/1/12 A

    13/1/12 A

    14/1/12 B

    15/1/12 B

    16/1/12 B

    17/1/12 B

    Please explain in such way so that i can implement it in visual studio 2010.

    Thanks in advance

    Try reading the response I posted in your other thread. You really need to stick with a single thread.

    _______________________________________________________________

    Need help? Help us help you.

    Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.

    Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.

    Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
    Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
    Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
    Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/