Saving Tweets with emojis using Twitter4J in a Mysql table
Posted on 2016-10-05
I have a Java application which uses Twitter4J to grab some Tweets and store them in a MySQL database.
When I output tweets to the console when running the Java application, they appear as strange characters which I am guessing is correct, just the console doesn't know how to render them. However when they're saved to the database the characters are saved as ????.
The database field is set to UTF8_bin.
I'm wondering how I can save the tweets and the emojis correctly in the mysql database?
To provide a little more information, this is for a web service which provides the tweets to a mobile application, which will be responsible for rendering the tweets.