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

后端 未结 12 1870
攒了一身酷
攒了一身酷 2020-12-07 08:45

I exported my database with JSON columns in it. After I migrated to a new server, my import crashed every time with an error like:

cannot create a JSO

12条回答
  •  攒了一身酷
    2020-12-07 09:24

    This odd issue was occurring when running a simple UPDATE query:

    update some_table set json_attr = '{"test":168}' where id = 123456;
    

    Restarting MySQL fixed it. Was not able to pinpoint the cause.

    Edit: We are using Aurora. It looks like it was related to us having a weird configuration where the same instance handled both master & slave/reader connections.

提交回复
热议问题