mirror of
https://github.com/php/php-src.git
synced 2025-01-10 04:54:47 +08:00
30 lines
666 B
PHP
30 lines
666 B
PHP
--TEST--
|
|
Bug #35517 (mysqli_stmt_fetch returns NULL)
|
|
--SKIPIF--
|
|
<?php require_once('skipif.inc'); ?>
|
|
--FILE--
|
|
<?php
|
|
include "connect.inc";
|
|
|
|
$mysql = new mysqli($host, $user, $passwd, "test");
|
|
|
|
$mysql->query("CREATE TABLE temp (id INT UNSIGNED NOT NULL)");
|
|
$mysql->query("INSERT INTO temp (id) VALUES (3000000897),(3800001532),(3900002281),(3100059612)");
|
|
|
|
$stmt = $mysql->prepare("SELECT id FROM temp");
|
|
$stmt->execute();
|
|
$stmt->bind_result($id);
|
|
while ($stmt->fetch()) {
|
|
var_dump($id);
|
|
}
|
|
$stmt->close();
|
|
|
|
$mysql->query("DROP TABLE temp");
|
|
$mysql->close();
|
|
?>
|
|
--EXPECTF--
|
|
%s(10) "3000000897"
|
|
%s(10) "3800001532"
|
|
%s(10) "3900002281"
|
|
%s(10) "3100059612"
|