In a query, trying to create the rolling totals of units. 3 fields; location, product ID, and units.

Whs ProdID Qty Rank
Whs1 0007160818 15 1
Whs1 0007666383 10 2
Whs1 0007090839 5 4
Whs1 0004244384 10 2

Calc field RunTot: DSum("Qty","qPicks2","[rank]>=" & [qpicks2].[ranking] & "")

I can rank them in another query, just when there is a tie in units the rank will be the same. And with the calculated field below, it is not working out. I cannot figure out though how to do a rolling total field based on the product id. Any suggestions please?