You guys are funny ... that's just a fancified database program -- you get this kind of ability if you own the right copy of MS Office. My PHP gallery software also does exactly this if I put how much I paid for my artwork into it when I update my gallery. It will total everything up on request and lets me view it in a printable format, too (only viewable to the gallery administrator, of course). It can break down by section or whatever you like, almost

. I love looking at how much money I've spent on Gundam Wing cels. It's so insane it almost makes me cry.
If you own MS Office with a program called MS Access, you don't need to pay $50 for something like this -- you can easily create your own database to track anything like that, too. Programs like this have been around for ages!