• kishor.patgir (5/9/2013)


    Hello Friends

    I want this type output.Here I want in first column how many members are join today(registration),and in second column sum of member before today,and third column the sum of two columns.I want to display this records in c#

    where user can pass current date(today date) and according to this he/she will get this output.If this possible in single query?

    I am pretty sure that this is possible in a single query.

    I am guessing that you also would like some help with query? If so, you will need to post ddl (create table statements) and sample data (insert statements) along with the desired output based on the sample data. Please take a few minutes to read the first article in my signature for best practices when posting questions.

    _______________________________________________________________

    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/