Re: Invalid byte sequence - Mailing list pgsql-admin

From Yambu
Subject Re: Invalid byte sequence
Date
Msg-id CALhHtcDQRXRqmZCT2LVk+F470-8qtrOux-W0DDnA=O4Dho2hVg@mail.gmail.com
Whole thread Raw
In response to Re: Invalid byte sequence  (Laurenz Albe <laurenz.albe@cybertec.at>)
List pgsql-admin
Thanks Laurenz, any suggestions on what tool I can use to clean the data?

On Thu, Jul 1, 2021 at 9:37 AM Laurenz Albe <laurenz.albe@cybertec.at> wrote:
On Thu, 2021-07-01 at 09:29 +0200, Yambu wrote:
> ERROR:  invalid byte sequence for encoding "UTF8": 0x00
> CONTEXT:  COPY table1, line 377617

That means that there is an ASCII 0 byte in a string somewhere in the file.
This character is not allowed in strings in PostgreSQL.
You will have to fix the data before you can load them into PostgreSQL.

Yours,
Laurenz Albe
--
Cybertec | https://www.cybertec-postgresql.com

pgsql-admin by date:

Previous
From: Laurenz Albe
Date:
Subject: Re: Invalid byte sequence
Next
From: Holger Jakobs
Date:
Subject: Re: Invalid byte sequence