#4287: FloatField will not handle infinity values
-------------------------------------+-------------------------------------
               Reporter:  oBeattie   |        Owner:  nobody
  (oliver@…                          |       Status:  new
                   Type:  Bug        |    Component:  Database layer
              Milestone:             |  (models, ORM)
                Version:  SVN        |     Severity:  Normal
             Resolution:             |     Keywords:  infinity, mysql,
           Triage Stage:  Accepted   |  float
    Needs documentation:  0          |    Has patch:  0
Patch needs improvement:  0          |  Needs tests:  0
-------------------------------------+-------------------------------------

Comment (by calmez):

 I looked at this with django from trunk and could reproduce the bug
 (working in sqlite3, not working in mysql).[[BR]]
 I had a look at mysql an found out that it is not possible to store
 infinity values in DOUBLE columns because "Standard SQL's FLOAT (not just
 MySQL's) is *not* an IEEE754 float" [#ref1 (1)].[[BR]]
 I patched it by using the smallest (-2147483648) and the biggest
 (2147483647) float value as -inf and inf.

 Would it be okay to fix that bug that way?

 ----
 [=#ref1 (1)] http://forums.mysql.com/read.php?39,220571,220573#msg-220573

-- 
Ticket URL: <http://code.djangoproject.com/ticket/4287#comment:4>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

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

Reply via email to