1

I changed my mysql database to utf-8 mb4, so that users could enter smileys from their mobile phones / mac. It works (users can enter smileys and those smileys are shown in the web app on supported devices), but whenever I have a look at the table contents (via terminal or mysql workbench) it shows each smiley as a single question mark. How exactly are those smileys saved? I assume they got a utf-8 mb4 code, but is there any way to look at those?

Thanks!

tpei
  • 671
  • 9
  • 26

1 Answers1

1

I suspect Workbench is running in utf8 mode, not utf8mb4. Change that.

To further verify that the data is stored correctly, do a SELECT HEX(col) ... to see the actual bytes stored. For example: => F09F9881

Rick James
  • 135,179
  • 13
  • 127
  • 222
  • See also http://stackoverflow.com/questions/38363566/trouble-with-utf8-characters-what-i-see-is-not-what-i-stored/ – Rick James Aug 19 '16 at 18:49