> On Sat, 2008-02-23 at 06:42 -0800, PB wrote: > > When trying to add 46.229253 to a floatfield > > I get displayed error: > > > Please enter a valid decimal number with a whole part of at most -19 > > digits > > > Any ideas?
On Sun, Feb 24, 2008 at 9:04 AM, PB <[EMAIL PROTECTED]> wrote: > > Hi, > > I'm using Django 0.96. The model has the lines: > > latitude = models.FloatField(null=True, max_digits=12, > decimal_places=31, blank=True) > longitude = models.FloatField(null=True, max_digits=12, > decimal_places=31, blank=True) > > Then when trying to use the admin tool it throws the above error. > Well, 12-31 is -19. I'm guessing (without checking the doc) that max_digits is supposed to include decimal_places, thus always be greater than or equal to it, and yours are not. If you want a whole part max of 12, decimal part max of 31, make your max_digits 12+31, not 12. Karen --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---