Possible Duplicate:
How to convert Python decimal to SQLite numeric?
I am having an issue with sqlite not showing values that are not 2 decimal places but when I test it on MySQL (workbench) it works fine. I doesn't give an error or anything but just disappears quietly. I want to get to the bottom of this voodoo so it doesn't come back to bite me.
MY_CHOICE = (
(Decimal('20.00'), '20'), /#doesnt work with sqlite
(Decimal('20.00'), '20.00'), /#doesnt work with sqlite
(Decimal('10.50'), '10.50'), /#doesnt work with sqlite
(Decimal('5.05'), '5.05'), /#works with sqlite
(Decimal('4.75'), '4.75'), /#works with sqlite
)
my_model = models.DecimalField(max_digits=6, decimal_places=2, choices=My_CHOICE, null=True, blank=True)
Any thoughts or ideas that might be helpful would be great. Thanks.