Christopher,

Your cursor method was pretty close to how I've ended up solving my task.

The problem I was trying to solve involved comparing a comulativeTotal with a previouscomulativeTotal.   I had a go at trying to do this in SQL this morning but due to the fact I'd be joining back to the same table once to get the comulative total and yet again to get back to the previouscomulative total it meant the query took ages.   I went with a embedded cursor in object script and created a recordset at the end to pass back both  comulativeTotal  and previouscomulativeTotal at the same time.   The iterative approach worked much better here as the two totals were close (one iteration away) ..