2

MySQL import: JSON with binary character set - stitcher.io

 3 years ago
source link: https://www.stitcher.io/blog/mysql-import-json-binary-character-set
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
MySQL import: JSON with binary character set
By continuing your visit to this site, you accept the use of cookies. Read more.

Scout APM helps PHP developers pinpoint N+1 queries, memory leaks & more so you can troubleshoot fast & get back to coding faster. Start your free 14-day trial today.

« back — written by Brent on January 09, 2018

MySQL import: JSON with binary character set

If you see this error when importing MySQL files:

cannot create a JSON value from a string with CHARACTER SET 'binary'

You should find and replace parts of the import file with the following regex:

Find: (X'[^,\)]*'), and replace by: CONVERT($1 using utf8mb4)

Source: StackOverflow.

Next up:  spatie/async

Follow me: TwitterRSSNewsletterPatreonGitHub

© 2020 stitcher.io — Cookies & Privacy


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK