On Tue, 2007-04-10 at 10:42 +0200, Michael Radziej wrote:
> Hi,
> 
> Malcolm Tredinnick wrote:
> > On Mon, 2007-04-09 at 18:35 +0400, Ivan Sagalaev wrote:
> >> Hello everyone!
> >>
> >> Malcolm has introduced DATABASE_CHARSET in changeset 4971[1] in a 
> >> unicode branch. If I remember correctly this setting was needed if we 
> >> have out internals in byte strings. But if internals are in unicode we 
> >> (theoretically) can feed them as utf-8 or even in pure unicode to a 
> >> database driver and let the driver do the encoding into a database's 
> >> internal charset. All is needed from Django side is to declare client 
> >> encoding to be always unicode (or utf-8, depending on backend). Now it's 
> >> done differently: we try to declare the client encoding equal to the 
> >> database encoding and decode to unicode upon receiving.
> >>
> >> Malcom was it done because of some backend specific things? If not I 
> >> could try the utf-8 approach I described on my machine.
> > 
> > Look closer, my friend. There is no DATABASE_CHARSET setting. :-)
> > 
> > There was one for a while in my sandbox (and in my planning), but it
> > turned out not to be needed: every currently supported backend has a way
> > to either detect the client encoding or set it. So it works exactly as
> > you propose.
> 
> Malcolm, your progress is great!
> 
> This should fix ticket #952, but I'm not sure. Can someone give me a
> second opinion, please?

I originally thought something like the solution in #952 would be needed
(hence the brief Life And Times of DATABASE_CHARSET). Then I realised
that it's probably overkill, because all the databases that handle
different character sets can do conversion between the client side of
the connection and the server side. So now I don't think #952 is needed.

However, I'd like to hold off closing all those tickets until we merge
the branch (maybe stick a unicode-branch keyword on them so we can find
them later). They're not fixed for "trunk" purposes yet (and our
understanding may change as people test things)

Regards,
Malcolm



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django developers" 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-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to