Você também pode usar CAST() para converter
        uma string para um conjunto de caracteres diferente. O novo
        formato é:
      
CAST ( character_string AS character_data_type
    CHARACTER SET character_set_name )
Exemplo:
SELECT CAST(_latin1'test' AS CHAR CHARACTER SET utf8);
        Você não usar uma cláusula COLLATE dentro
        de um CAST(), mas você pode usá-la fora,
        isto é, CAST(... COLLATE ...) é ilegal mas
        CAST(...) COLLATE ... é permitido.
      
Exemplo:
SELECT CAST(_latin1'test' AS CHAR CHARACTER SET utf8) COLLATE utf8_bin;
        Se você usar CAST() sem especificar
        CHARACTER SET, então o conjunto de
        caracteres e collation resultante são o conjunto de caracteres
        da conexão/literal e a sua collation padrão. Se você usar
        CAST() com CHARACTER SET
        X, então o conjunto de caracteres resultante é
        X e a collation resultante é a collation
        padrão de X.
      
This is a translation of the MySQL Reference Manual that can be found at dev.mysql.com. The original Reference Manual is in English, and this translation is not necessarily as up to date as the English version.

