Author: bouldersprinters
Date: 2007-05-31 13:55:16 -0500 (Thu, 31 May 2007)
New Revision: 5394

Modified:
   django/branches/boulder-oracle-sprint/django/db/backends/oracle/base.py
Log:
boulder-oracle-sprint: Fixed #4440.


Modified: 
django/branches/boulder-oracle-sprint/django/db/backends/oracle/base.py
===================================================================
--- django/branches/boulder-oracle-sprint/django/db/backends/oracle/base.py     
2007-05-31 16:09:49 UTC (rev 5393)
+++ django/branches/boulder-oracle-sprint/django/db/backends/oracle/base.py     
2007-05-31 18:55:16 UTC (rev 5394)
@@ -461,7 +461,7 @@
 
         def resolve_columns(self, row, fields=()):
             from django.db.models.fields import DateField, DateTimeField, \
-                TimeField, BooleanField, NullBooleanField, DecimalField
+                TimeField, BooleanField, NullBooleanField, DecimalField, Field
             values = []
             for value, field in map(None, row, fields):
                 if isinstance(value, Database.LOB):
@@ -470,7 +470,7 @@
                 # order to adhere to the Django convention of using the empty
                 # string instead of null, but only if the field accepts the
                 # empty string.
-                if value is None and field.empty_strings_allowed:
+                if value is None and isinstance(field, Field) and 
field.empty_strings_allowed:
                     value = ''
                 # Convert 1 or 0 to True or False
                 elif value in (1, 0) and isinstance(field, (BooleanField, 
NullBooleanField)):


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

Reply via email to