From: | Feike Steenbergen <feikesteenbergen(at)gmail(dot)com> |
---|---|
To: | ROS Didier <didier(dot)ros(at)edf(dot)fr> |
Cc: | "pgsql-sql(at)postgresql(dot)org" <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: ERROR: invalid byte sequence for encoding "UTF8": 0xe9 0x6d 0x61 |
Date: | 2017-10-11 06:20:34 |
Message-ID: | CAK_s-G2nVwyewe1_ucGbLXQUoA9egCqFuS4NjOxEy-e4dc5uMQ@mail.gmail.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
On 10 October 2017 at 15:28, ROS Didier <didier(dot)ros(at)edf(dot)fr> wrote:
> -- Securisation du search_path: les schémas de confiance, puis
> The error message is :
>
> ERROR: invalid byte sequence for encoding "UTF8": 0xe9 0x6d 0x61
I'm guessing your client is actually using an encoding of something like
LATIN1, but is identifying itself as UTF8.
The sequence 0xe9 0x6d 0x61 in LATIN1 is "éma", which matches your line
with 'les schémas'.
However, 0xe9 is invalid in UTF8.
To validate this, you could do the following:
select current_setting('client_encoding');
set client_encoding to 'LATIN1';
select current_setting('client_encoding');
before executing your command.
By the way, did you know you can set configuration parameters per function
on a different way as well:
CREATE OR REPLACE FUNCTION abc()
RETURNS boolean
LANGUAGE SQL AS $$
SELECT true;
$$
SET search_path TO 'public, pg_temp';
From | Date | Subject | |
---|---|---|---|
Next Message | ROS Didier | 2017-10-11 07:49:25 | Re: ERROR: invalid byte sequence for encoding "UTF8": 0xe9 0x6d 0x61 - fixed |
Previous Message | ROS Didier | 2017-10-10 13:28:56 | ERROR: invalid byte sequence for encoding "UTF8": 0xe9 0x6d 0x61 |