Last night I experienced again why open source works. I was beating my head getting sorting to work in Ruport (Ruby Reporting Package), and instead of opening a support ticket I posted to the mailing list:
http://lists.stonecode.org/pipermail/ruport-stonecode.org/2006-August/thread.html#227
`Nuff said.