patrick.just4fun at gmail.com
Wed Mar 3 12:24:41 CET 2010
> i am looking for more informations about encoding in python:
> i've read that Amazon SimpleDB accepts every string encoded in UTF-8.
> How can I encode a string? And, what's the default string encoding in
I think the safest way is to use unicode strings in your application and
convert them to byte strings if needed, using the encode and decode methods.
> the other question is about mysql DB: if i have a mysql field latin1 and
> extract his content in a python script, how can I handle it?
if you have a byte string s encoded in 'latin1' you can simply call:
to get the unicode string.
More information about the Tutor