Specifying Character Encoding / Character Sets such as UTF-8 using the MySQL JDBC Driver

To force the MySQL JDBC driver to use a particular character set / character encoding when connecting to a database, there are a couple of properties that need to be set on the connection to ensure the correct behavior.

However, it is also very important that if you are working with characters such as Japanese or Chinese characters, that you use a font that can display these characters. An example of a font that can display characters such as these is Arial Unicode MS.

After making sure you have chosen a font that can display the characters you are working with, you can create a new MySQL connection profile. This can be done via the "Add Connection Profile" screen.

On this screen there is a Conn. Properties field with a "Configure" button. Click this button and enter the following information in the name and value fields (this example assumes UTF-8 as the character encoding):

Name: characterEncoding
Value: UTF-8

Name: useUnicode
Value: true

Note: When using a character encoding such as UTF-8, the useUnicode property should be set.