[DBD-SQLite] Weird UTF-8 problem

Michael Lackhoff michael at lackhoff.de
Mon Nov 2 05:39:05 GMT 2009


I encountered something that looks very odd to me with 1.25.
What makes it so weird is that I cannot reproduce it in a simple test
script but in my application with all sorts of other components
(mod_perl, CGI::Application, Template::Toolkit) database values somehow
"forget" their UTF-8 flag.
I set $dbh->{unicode} = 1 then I get some data from the DB then do this
test:
Encode::is_utf8($data)
As I said, when I print the result of the test from my test script it
gives "1", when I log it from my application I get "0".

Of course the first suspects in such a situation are all the other
components I am using but then I compiled the latest development version
(1.26_06) and with this version it works (the UTF-8 flag is not lost in
the application).

I have two questions from this:
- any idea what I could do to not loose the UTF-8 flag with 1.25? I
would rather prefer not to require bleeding edge in my application.
- is there a chance to make a new stable version? Then at least it is
easier to meet the requirement.

-Michael





More information about the DBD-SQLite mailing list