SQL to NOCODB : encoding issue

Hello everyone,

I have a big postgres database containing several thousand rows I want to transfer to nocodb’s native database system.

However, for a lots of rows and for different fields, I get the following error:

... - Incorrect string value: '\xE2\x89\xA4 2 ...' for column 'beneficiaires' at row 1

I understand it’s an encoding issues but all the function nodes I tried to build with chatgpt failed. I need the HTML to remain “functional” because I have a sync between NocoDB and Wordpress.

Here is the workflow with some sample data:

I am running v1.70.1 on Docker, managed via Portainer on a local Ubuntu Server.

I hope someone can help me out! :smiley:
Thank you very much,
Joachim

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hello,
It’s me again.

Searching more, I found this post:

Which brought me to this:

I will keep investigating because I am not sure I understand the discussion :sweat_smile:

1 Like

Hi,

The gist of those other conversations is that with the default installation of MariaDB, the database was set up in such a way that some unicode characters were not accepted and caused a crash.

In my case it did accept utf8 characters encoded on 3 bytes, but not utf8 characters encoded on 4 bytes, because of how MariaDB considers to be utf8 (vs the so-called utf8mb4, a superset of utf8). If you look closely you’ll see my error message was similar to yours but had 4 bytes grouped together. Your error shows only 3 bytes. This tells me the situation is not exactly identical; you might be getting an error on a character that would be accepted as utf8. Maybe your database is set up for some encoding that is not even utf8-compatible? this is a bit surprising as i believe utf8 was the default encoding when I installed mariaDB - though I could be misremembering.

Playing with the encoding commands in mariaDB to determine what encoding your database and tables are using (you’ll want to check those you’re trying to insert data into) might put you on the right track.

Disclaimer: I’ve not been looking at this closely since those original conversations, I’m assuming nothing has fundamentally changed since then.

3 Likes

Thank you @Pierric, I fed all the conversations to chatgpt and it gave me a bunch of commands to move all my existing tables to the right encoding and to set it for future tables. It is solved :smiley:

Thank you for pointing me in the right direction!!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.