Bug #30545 | Character set '#33' is not a compiled character set and is not specified in the | ||
---|---|---|---|
Submitted: | 21 Aug 2007 20:20 | Modified: | 7 Sep 2007 16:59 |
Reporter: | Stanislav Izotov | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server: Charsets | Severity: | S2 (Serious) |
Version: | 5.0.45 | OS: | Windows (2003 Server) |
Assigned to: | CPU Architecture: | Any |
[21 Aug 2007 20:20]
Stanislav Izotov
[21 Aug 2007 20:30]
Sveta Smirnova
Thank you for the report. But version 5.0.24 is quite old. Please upgrade to current version 5.0.45, try with it and if you can repeat the issue create simple PHP test case we can download and try in our environment. Also provide MySQL configuration file.
[21 Aug 2007 22:21]
Stanislav Izotov
I updated to 5.0.45 and it still reproduces. As a test case just install wordpress and set it to UTF-8 aswell and write some Swedish-letters in the blog (åäö ÅÄÖ). If it wont reproduce I can provide more information to pin down what settings you need to reproduce.
[23 Aug 2007 7:52]
Hartmut Holzgraefe
AFAIR problem is the mysql library code that comes bundled with PHP, only when PHP is compiled against a mysql client library that was itself compiled with --with-extra-charsets=all or if there is a full mysql client installation on the machine running PHP and the PHP mysql extension configured with the right pathes to find the loadable charset files charset support works fine with all charsets. For unix systems the solution is easy: compile PHP with --with-mysql=/mysql/install/path and everything is set up ok for your system. For windows compiling stuff yourself is usually not an option so you need a PHP mysql extension DLL compiled with the right configuration, not the generic minimalistic one that you get with the mysql client code bundled with PHP (which is so generic and minimalistic for a reason though ...) I *think* the PHP extensions for windows that we provide on http://dev.mysql.com/downloads/connector/php/ have been build with all this in mind, not being a windows user myself i can't guarantee (or even test) this though ...
[7 Sep 2007 16:59]
Sergei Golubchik
*.conf files were used in MySQL 4.0 and before. Starting from 4.1 we use xml charset files. As your error message mentions .conf files it means you're using old client library. Please upgrade.
[17 Mar 2008 20:50]
Edgar Ogando
I had this problem within some pages, I couldn't find an answer that solved the problem, but somehow I did: Problem: "File 'c:\mysql\share\charsets\?.conf' not found (Errcode: 2) Character set '#33' is not a compiled character set and is not specified in the 'c:\mysql\share\charsets\Index' file" Runnig: Windows XP (IIS 5.1) MySQL Server 4.1 (mysql-essential-4.1.22) PHP 4.4.7 (CGI/FastCGI) MySQL Client API version 3.23.49 In "C:\Program Files\MySQL\MySQL Server 4.1\my.ini" file, I found that the charset directive was repeated twice, at the beginning and at the end, so I just deleted the final lines and the error just disappeared. REMOVING THIS SOLVED THE #Set the default character set. default-character-set=utf8 #Path to the character-sets directory. character_sets-dir=C:/Program Files/MySQL/MySQL Server 4.1/share/charsets/ It looks like the MySQL Administration tool just appended this even if it was already in the file. This is a weird "problem" as some people managed to solve by doing other changes or even recompiling binaries and all that...
[11 May 2008 22:35]
Jesus Trujillo
After several tests over MySQL 4, I found that this bug only appears when: 1) There's any response in the PHP script BEFORE the MySQL connection. I mean... THIS FAILS: echo "hello world!"; $ConnectionId=mysql_connect($ConnectionServer,$ConnectionUser,$ConnectionionPass); THIS RUNS: //echo "hello world!"; $ConnectionId=mysql_connect($ConnectionServer,$ConnectionUser,$ConnectionionPass); AND 2) There's no default-character-set .xml file in /share/charsets/ folder. So, change your default-character-set to latin1 OR try to avoid using response commands (echo, var_dump, printf, etc.) in your PHP script before any MySQL statement. I chose the first solution because sometimes is not possible the second option. Hope this will help.