Unicode/utf-8 data in SQL Server

Laurent Pointal laurent.pointal at limsi.fr
Wed Aug 9 03:38:07 EDT 2006


John Machin a écrit :
> The customer should be very happy if you do
> text.decode('utf-8').encode('cp1252') -- not only should the file
> import into Excel OK, he should be able to view it in
> Word/Notepad/whatever.

+
text.decode('utf-8').encode('cp1252',errors='replace')

As cp1252 may not cover all utf8 chars.

Laurent.



More information about the Python-list mailing list