Decimals

Tgone bapolis at gmail.com
Tue Jun 13 04:48:36 EDT 2006


Hello,

I have a price column in a MySQL table: price decimal(5,2)

When I access them in Python with SQLObject, prices display as 15.0
instead of 15.00. Why is this happening? I can't figure out why Python
is trimming off the hundredth place. I'm not doing any formatting...

Thanks,
Tony




More information about the Python-list mailing list