SELECT * , CAST ( `BIN_NAME` AS CHARACTER CHARACTER SET `utf8` ) AS SCHEMA_NAME FROM ( SELECT BINARY `s` . `SCHEMA_NAME` AS `BIN_NAME` , `s` . `DEFAULT_COLLATION_NAME` FROM `information_schema` . `SCHEMATA` `s` GROUP BY BINARY `s` . `SCHEMA_NAME` , `s` . `DEFAULT_COLLATION_NAME` ORDER BY BINARY `SCHEMA_NAME` ASC ) `a` 