I'm wondering how people deal with the DecimalField in django?

I've just discovered the amount of typecasting I have to do to work
with this field, example:

field1 = models.DecimalField(...)

you can't do :

    y = field1 / 100.0

you have to do y = field1 / Decimal(100)

But then you can't do this either:

y = field1 / Decimal(a + b / 2.0)

Am I missing something, or does the Decimal field just require a ton
of typecasting to keep it sane?

Thanks

John
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to