[Zope] UTF8 encoding

Tino Wildenhain tino at wildenhain.de
Wed Jun 18 02:56:21 EDT 2008


Hi Garry,

Garry Saddington wrote:
> I am getting a few of this type of error only coming from Windows 
> machines, does anyone know how to sort this out?
> 
> ProgrammingError: ERROR: invalid byte sequence for encoding "UTF8": 0xa3 
> HINT: This error can also happen if the byte sequence does not match the 
> encoding expected by the server, which is controlled by 
> "client_encoding". insert into departmentplanning (planningcategoryid, 
> taskid, subtasks, moneval, timescale, budget, success, subjectid, 
> teacherid) VALUES (1 , 186 , 'Identify suitable tasks and activities for 
> all G+T pupils and students ' , 'ADE- liaise with HS and GE' , 'JUL08 
> on' , 'SOme activities could be bought in ~£50' , 'All G+T pupils and 
> students given opportunity for enhanced work' , 1787, 41 )

You give us very little to base our suggestions on. From what I see
it looks like you are using a RDBMS, seems to be Postgres, and
the python binding (psycopg?) reports you this exeption. It also gives
you hints about the reasons. Maybe you see if you can follow that?
IIRC, recent ZSQL-driver for postgres allow for setting the encoding,
you should use that, also setting this in the database for the
user you are connecting with should be possible if everything else fails.

In any case please try do give more details about your setup.

Cheers
Tino

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3241 bytes
Desc: S/MIME Cryptographic Signature
Url : http://mail.zope.org/pipermail/zope/attachments/20080618/6bda4fd5/smime.bin


More information about the Zope mailing list