#31938 [Opn->Fbk]: mysqli_prepare + MD5 problem

From: Date: Mon, 28 Feb 2005 19:43:24 +0000
Subject: #31938 [Opn->Fbk]: mysqli_prepare + MD5 problem
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-76910@lists.php.net to get a copy of this message
ID: 31938 Updated by: sniper@php.net Reported By: stas at okean dot de -Status: Open +Status: Feedback Bug Type: MySQLi related Operating System: Windows XP Professional PHP Version: 5.0.3 New Comment: Please try using this CVS snapshot: http://snaps.php.net/php5-latest.tar.gz For Windows: http://snaps.php.net/win32/php5-win32-latest.zip Previous Comments: ------------------------------------------------------------------------ [2005-02-11 19:26:35] stas at okean dot de Description: ------------ When using mysqli_perpare/execute/bind/fetch combination to retrieve a MD5 hash from the database php replaces the last character of the hash throug a hex(00) character. A mysqli_query/fetch_row works correctly. Reproduce code: --------------- $mysqli->prepare("SELECT MD5('a')"); $ps->execute(); $ps->bind_result($hash); $ps->fetch(); $ps->close(); echo $hash; Expected result: ---------------- 0cc175b9c0f1b6a831c399e269772661 Actual result: -------------- 0cc175b9c0f1b6a831c399e26977266 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31938&edit=1

« previous php.bugs (#76910) next »