[Dbix-class] Unicode woes
Dave Howorth
dhoworth at mrc-lmb.cam.ac.uk
Wed Jan 8 15:45:50 GMT 2014
Patrick Meidl wrote:
> On Wed, Jan 08 2014, Dave Howorth <dhoworth at mrc-lmb.cam.ac.uk> wrote:
>
>> But when I run my DBIC program and dump the value, I see single-byte
>> characters such as \xA0, \x91, \x92 which I believe are Windows-1252.
>
> two things I can think of:
>
> - do your Result classes 'use utf8'?
No, but I don't have any Unicode strings in my source.
> - when you dump the data (write to file), are you using an utf8
> filehandle? e.g.
>
> use open ":encoding(utf8)";
>
> or
>
> binmode(OUT, ":utf8");
Doh! Also no, and as soon as I do the dump file has Unicode byte
sequences in it. Thank you!
So it looks like all I need to do now is figure out how to tell
Template::Toolkit to do that when it sees Unicode data.
> other than that, I found this page quite informative:
>
> http://mysql.rjweb.org/doc.php/charcoll
Thanks, I'll have a read of that as well.
Cheers, Dave
> HTH
>
> patrick
More information about the DBIx-Class
mailing list