Error character with byte sequency 0xc2 0x96 in encoding "UTF8" has no equivalent in encoding "WIN1252"

Discussion of open issues, suggestions and bugs regarding usage of dbExpress drivers for PostgreSQL in Delphi and C++Builder
Post Reply
edmilsonst
Posts: 1
Joined: Tue 20 Oct 2020 20:28

Error character with byte sequency 0xc2 0x96 in encoding "UTF8" has no equivalent in encoding "WIN1252"

Post by edmilsonst » Tue 20 Oct 2020 20:48

Hello!
After converting the Firebird database to the Postgre database I came across the following error: character with byte sequence 0xc2 0x96 in encoding "UTF8" has no equivalent in encoding "WIN1252". This occurs in a field of type "bytea". For the display, I do the conversion as follows: CAST (substring (convert_from (CAST (psi.especificacao as bytea), 'latin1') from 1 for 100) AS VARCHAR (100))
It works perfectly in SQL_Manager or PgAdmim, but when the query is executed by the system, the error is presented with encoding. I use DBExpress with the CBuilder IDE.
Has anyone been through something like this?
Is there any way to configure the Devart driver so that it doesn't?

thankful

oleg0k
Devart Team
Posts: 131
Joined: Wed 11 Mar 2020 08:28

Re: Error character with byte sequency 0xc2 0x96 in encoding "UTF8" has no equivalent in encoding "WIN1252"

Post by oleg0k » Thu 17 Dec 2020 11:14

Hello,
Unfortunately, we couldn't reproduce the issue.
Please send us an example that uses dbExpress driver for PostgreSQL and demonstrates the incorrect behavior, along with DDL scripts for creating and populating the database objects (or the backup file/database file).
Send them to us through the form: https://devart.com/company/contactform.html

wbr, Oleg
Devart Team

Post Reply