List of usage examples for io.vertx.mysqlclient MySQLConnectOptions setCharset
public MySQLConnectOptions setCharset(String charset)
From source file:examples.MySQLClientExamples.java
public void configureConnectionCharset() { MySQLConnectOptions connectOptions = new MySQLConnectOptions(); // set connection character set to utf8 instead of the default charset utf8mb4 connectOptions.setCharset("utf8"); }
From source file:examples.MySQLClientExamples.java
public void configureConnectionCollation() { MySQLConnectOptions connectOptions = new MySQLConnectOptions(); // set connection collation to utf8_general_ci instead of the default collation utf8mb4_general_ci // setting a collation will override the charset option connectOptions.setCharset("gbk"); connectOptions.setCollation("utf8_general_ci"); }