Cast Functions and Operators 1. Download the tar.gz packages for  mecab  and  mecab-ipadic  from http://taku910.github.io/mecab/ #download. As of February, 2016, the latest available packages are  mecab-0.996.tar.gz  and mecab-ipadic-2.7.0-20070801.tar.gz . 2. Install  mecab : 3. Install  mecab-ipadic : 4. Compile MySQL using the  WITH_MECAB  CMake option. Set the  WITH_MECAB  option to  system  if you have installed  mecab  and  mecab-ipadic  to the default location. tar zxfv mecab-0.996.tar cd mecab-0.996 ./configure make make check su make install tar zxfv mecab-ipadic-2.7.0-20070801.tar cd mecab-ipadic-2.7.0-20070801 ./configure make su make install SELECT CONVERT(’test’ USING utf8mb4); SELECT CONVERT(_latin1’Müller’ USING utf8mb4); INSERT INTO utf8mb4_table (utf8mb4_column) SELECT CONVERT(latin1_column USING utf8mb4) FROM latin1_table; CONVERT( string , CHAR[( N )] CHARACTER SET  charset_name ) 12.11 Cast Functions and Operators Table 12.15 Cast Functions and Operators Name Description BINARY Cast a string to a binary string CAST() Cast a value as a certain type CONVERT() Cast a value as a certain type Cast functions and operators enable conversion of values from one data type to another. CONVERT()  with a  USING  clause converts data between character sets: In MySQL, transcoding names are the same as the corresponding character set names. Examples: CONVERT( expr  USING  transcoding_name ) To convert strings between character sets, you can also use  CONVERT( expr ,  type )  syntax (without USING ), or  CAST( expr  AS  type ) , which is equivalent: 2230 If you defined a custom installation directory, set  WITH_MECAB  to the custom directory. For example: -DWITH_MECAB=system -DWITH_MECAB=/path/to/mecab