On Mon, Mar 1, 2010 at 7:11 AM, Tom Evans <tevans...@googlemail.com> wrote:

> On Mon, Mar 1, 2010 at 11:52 AM, PyMan <claudio.marino...@rsoft.it> wrote:
> > up, anyone?
> >
>
> Django expects your database backend to return unicode values. Your DB
> backend returns latin1 byte strings. Therefore, django gets confused
> when you try to save the content, as it believes it has unicode values
> and it doesn't.
>


Clarification: Django will accept bytestrings instead of unicode values, but
if they need to be converted to unicode values Django will assume they are
encoded in utf-8, so passing latin1 bytestrings can run into trouble.


> The solution is to fix your backend so that it works correctly with django:
>

Yes. Note the backend in use here does state that it accepts and returns
unicode: http://code.google.com/p/django-pyodbc/. So how latin1 bytestrings
are coming into play is a question best answered by the developers of that
backend.

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-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