Re: Please help to find running total in

Posted By: KF at 14:34:05 on Tuesday the 21st of November 2006

You can try this (It works in my query browser but not my Delphi query component, unfortunately)

select @rtot:=@rtot+Number1+(Number2 * -1) as rtot,t.* from (select @rtot:=0) rt,MyTable as t where SomeCriteria group by MyColumn order by MyColumn


Reply to this comment

Name
Email
URL (optional)
Title of Comment
Comment
HTML Allowed:
a,code,strong,em
I would like to be e-mailed any response to my comment.