I have a MySQL database hosted on a windows server. When I query for a particular record from various windows machines using mysql console I get Päivi
(incorrect). When I query for the same record from various *nix machines using mysql console I get Päivi
(correct). The query I'm using is a simple SELECT firstname FROM users WHERE id = 12345;
.
My database collation is utf8, the field collation is utf8, and I've tried using set names 'utf8';
prior to running my queries.
Why would the windows machines return a different result? Could windows be missing certain characters? Is this normal/expected behavior? I'm not an encoding nor language expert so any feedback would be helpful.
I'm not sure if a windows console is still multi-byte using the ANSI code page. If so that would be the problem. The results might be correct but the console displays them incorrectly.
After you connect to the server, from the MySQL console client, type the following command to view your current client characterset:
To set it, use the following command: