Error: invalid byte sequence for encoding

Discussion of open issues, suggestions and bugs regarding PgDAC (PostgreSQL Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
dschuch
Posts: 75
Joined: Thu 05 Feb 2009 15:29
Location: Dresden

Error: invalid byte sequence for encoding

Post by dschuch » Sun 13 Sep 2009 17:19

Hy,

with PostgreSQL 8.4 there is the following error if i try to insert that RTF-String as a (Memo)field of a Query:

Error: invalid byte sequence for encoding
{\rtf1\ansi\deff0{\fonttbl{\f0\fnil\fcharset0 Arial;}}
\viewkind4\uc1\pard\lang1031\fs20 *
\par }
UPDATE art
SET
ak_auftxt = $1, ak_auftxt_rtf = $2
WHERE
dbrid = $9
:ak_auftxt(Memo,IN)=
:ak_auftxt_rtf(Memo,IN)=
:Old_dbrid(String[8],IN)='17766083'

Error: invalid byte sequence for encoding "SQL_ASCII": 0x00

dschuch
Posts: 75
Joined: Thu 05 Feb 2009 15:29
Location: Dresden

Post by dschuch » Sun 13 Sep 2009 20:30

i have startet a post in the postgresql forum too:

http://archives.postgresql.org/pgsql-ge ... g00453.php

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Mon 14 Sep 2009 10:53

RTF often ends with zero character. You should remove this character from an RTF value before assigning it to a parameter or a field.

Post Reply