Bug #70384 [Csd]: mysqli_real_query(): Unknown type 245 sent by the server

From: Date: Thu, 10 Dec 2015 09:49:55 +0000
Subject: Bug #70384 [Csd]: mysqli_real_query(): Unknown type 245 sent by the server
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-197764@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=70384&edit=1 ID: 70384 Updated by: andrey@php.net Reported by: marc at infomarc dot info Summary: mysqli_real_query(): Unknown type 245 sent by the server Status: Closed Type: Bug Package: MySQLi related Operating System: Linux PHP Version: 7.0.0RC1 Assigned To: mysql Block user comment: N Private report: N New Comment: JTerry, can you provide a minimal test case that fails, together with information about PHP version (I suppose 5.6.16), whether libmysql or mysqlnd is used by mysqli (phpinfo() will tell this). Best, Andrey Previous Comments: ------------------------------------------------------------------------ [2015-12-09 01:47:21] jterry at joeterry dot com It looks like the issue is resolved when using the approach given by the OP, however, it's still reproducible in 5.6.16 with the following: $query = mysqli_query($db, $sql); // table contains a JSON field if (false !== $query) { while ($row = mysqli_fetch_array($query) { // do something } } ------------------------------------------------------------------------ [2015-10-05 14:24:13] lucian dot depold at gmail dot com Problem does not seem to be resolved in 5.6.14 for windows. Newer snapshots are somehow not available. ------------------------------------------------------------------------ [2015-09-30 07:06:55] andrey@php.net Hi Marc, I forgot that. A fix got just pushed to 5.6, 7.0 and 7.1 Thanks! ------------------------------------------------------------------------ [2015-09-29 21:30:20] marc at infomarc dot info Hi Andrey, I believe you also need to register MYSQLI_TYPE_JSON in ext/mysqli/mysqli.c. Marc Delisle ------------------------------------------------------------------------ [2015-09-29 14:02:08] andrey@php.net The fix for this bug has been committed. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. For Windows: http://windows.php.net/snapshots/ Thank you for the report, and for helping us make PHP better. Fixed in PHP-5.6, PHP-7.0 and master (PHP-7.1) Thank You for your report ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=70384 -- Edit this bug report at https://bugs.php.net/bug.php?id=70384&edit=1

« previous php.bugs (#197764) next »