Can a date be loaded into a DateField using Django's loaddata admin
feature? I have a JSON file that I'm using to bulk load data into my
app. When you dumpdata, date fields are outputted in the format yyyy-
mm-dd. However, if you try loading data back in with the same format,
the field is treated as a string and the load fails.

For example, I have a field authorization_date of type
models.DateField(). When the value of a field is "2001-12-14", I get
the following error:

> Warning: Data truncated for column 'authorization_date' at row 1

So how can I load dates using Django's loaddata?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@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