Hi
I need to create a new column in a table, that will hold a commulative percent values.
Let's assume we have a table of this structure :
Month Sales Percent
1 1000 0.1
2 7000 0.7
3 2000 0.2
I have calculated the 3'rd colomn (Percent).
Now what I need is a commulative percent column, meaning:
ComPer
0.1
0.8
1
Can you please assist me in building such a column?
Esch value in this column depends on the value before.
I wonder if a cursor holds the answer, but since I have about 3 million records, I assume cursors is not the preffered solution (if it's a solution at all).
Thanks in advance
Erez
I need to create a new column in a table, that will hold a commulative percent values.
Let's assume we have a table of this structure :
Month Sales Percent
1 1000 0.1
2 7000 0.7
3 2000 0.2
I have calculated the 3'rd colomn (Percent).
Now what I need is a commulative percent column, meaning:
ComPer
0.1
0.8
1
Can you please assist me in building such a column?
Esch value in this column depends on the value before.
I wonder if a cursor holds the answer, but since I have about 3 million records, I assume cursors is not the preffered solution (if it's a solution at all).
Thanks in advance
Erez