T-SQL 2005

  • Anybody a bit of a running total Guru !

    I have a table that I want to be able to add a column for a running total for GWP.

    GWP is a Float field and the date field is a INT in the format of 200701,200702,200703 etc - ENDING WITH THE LATEST MONTH.

    My data table does not have a unique ID to each row of data.

    The end user can view the table in various slices such as Year to date Current and previous - although this could be restricted if caused problems with the running total

    Any help in how to script this would be totally appreciated

    Thanks:-D

  • ian.dunlop (7/10/2009)


    Anybody a bit of a running total Guru !

    I have a table that I want to be able to add a column for a running total for GWP.

    GWP is a Float field and the date field is a INT in the format of 200701,200702,200703 etc - ENDING WITH THE LATEST MONTH.

    My data table does not have a unique ID to each row of data.

    The end user can view the table in various slices such as Year to date Current and previous - although this could be restricted if caused problems with the running total

    Any help in how to script this would be totally appreciated

    Thanks:-D

    Will need the DDL for the table, including existing indexes; sample data, in a readily consummable format that can be cut/paste/run in SSMS to load the table; expected results based on the sample data, need something to verify our code; and what you have done so far to solve your problem.

    Just noticed this was your first post. Please read the first article I reference below regarding asking for help. Follow the guidelines in that article when it comes to posting the requested information as you will get fast and better help.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply