You get get no data output at all when you add a last-of? Or just just no last-of data?
Anyway, the first thing that occurs to be is that you are sorting by 1,2,3 but your accum statement is by 3,2,1. That looks wrong to me, and could be messing things up.