#32384 [NEW]: old libmysqlclient caused data loss in MySQL 4.1 DB
| From: | ustupkin at mail dot primorye dot ru | Date: | Sun, 20 Mar 2005 13:59:13 +0000 |
| Subject: | #32384 [NEW]: old libmysqlclient caused data loss in MySQL 4.1 DB | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-75562@lists.php.net to get a copy of this message | ||
From: ustupkin at mail dot primorye dot ru
Operating system: windows
PHP version: 4.3.10
PHP Bug Type: MySQL related
Bug description: old libmysqlclient caused data loss in MySQL 4.1 DB
Description:
------------
http://bugs.mysql.com/bug.php?id=8420&thanks=2¬ify=7
Windows version of PHP 4.x.x
compiled with old libmysqlclient - 3.xx.xx. Moreover, it has hardcoded
path to mysql charset dir.
Reproduce code:
---------------
<?php
$link = mysql_connect('localhost:3307', 'root', '');
$set = mysql_query('SET NAMES CP1251',$link);
$set = mysql_query('SET COLLATION_CONNECTION=CP1251_GENERAL_CI',$link);
$charset = mysql_client_encoding($link);
printf ("current character set is %s\n", $charset);
?>
echoes
"File 'c:\mysql\share\charsets\?.conf' not found (Errcode: 22)
Character set '#51' is not a compiled character set and is not specified
in the
'c:\mysql\share\charsets\Index' file
current character set is latin1"
There is an obvious bug in every win32 distribution of MySQL 4.1.x.
There is no sense to setting such options as:
character-sets-dir=c:/mysql/share/charsets
default-character-set=cp1251
In any case as result - something like this:
File 'c:\mysql\share\charsets\?.conf' not found (Errcode: 22)
Character set '#51' is not a compiled character set and is not specified
in the
'c:\mysql\share\charsets\Index' file
--
Edit bug report at http://bugs.php.net/?id=32384&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=32384&r=trysnapshot4
Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=32384&r=trysnapshot50
Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=32384&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=32384&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=32384&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=32384&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=32384&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=32384&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=32384&r=support
Expected behavior: http://bugs.php.net/fix.php?id=32384&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=32384&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=32384&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=32384&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=32384&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=32384&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=32384&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=32384&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=32384&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=32384&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=32384&r=mysqlcfg