May 21, 2003 at 5:27 am
Problem solved with cursors
Edited by - botond.baika on 05/21/2003 07:40:42 AM
🙂
May 21, 2003 at 8:17 am
SELECT
Identity(BigInt, 1, 1) As Counter,
'1' codes, [Values], 0 as RunningSum
INTO #Tmp
FROM ExTbl
declare @x int
select top 1 @x = [values] from #Tmp
Update #Tmp
SET RunningSum = @x,
@x = @x + [Values]
Gregory Larsen, DBA
If you looking for SQL Server Examples check out my website at http://www.geocities.com/sqlserverexamples
Gregory A. Larsen, MVP
May 22, 2003 at 7:39 am
Thank you! :))
Your's is faster and much more simple. 🙂
Probably that's why I didn't manage to figure out myself... it was too simple! 🙂
Thanx again for your time!
Best regards,
Botond
Edited by - botond.baika on 05/23/2003 03:22:23 AM
🙂
July 30, 2005 at 7:04 am
pls reply me
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply