summaryrefslogtreecommitdiff
path: root/ext/mysqli/tests/016.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/mysqli/tests/016.phpt')
-rw-r--r--ext/mysqli/tests/016.phpt25
1 files changed, 25 insertions, 0 deletions
diff --git a/ext/mysqli/tests/016.phpt b/ext/mysqli/tests/016.phpt
new file mode 100644
index 0000000000..7d84c29655
--- /dev/null
+++ b/ext/mysqli/tests/016.phpt
@@ -0,0 +1,25 @@
+--TEST--
+mysqli fetch user variable
+--FILE--
+<?php
+ include "connect.inc";
+
+ /*** test mysqli_connect 127.0.0.1 ***/
+ $link = mysqli_connect("localhost", $user, $passwd);
+
+ mysqli_select_db($link, "test");
+
+ mysqli_query($link, "SET @dummy='foobar'");
+
+ $stmt = mysqli_prepare($link, "SELECT @dummy");
+ mysqli_bind_result($stmt, &$dummy);
+ mysqli_execute($stmt);
+ mysqli_fetch($stmt);
+
+ var_dump($dummy);
+
+ mysqli_stmt_close($stmt);
+ mysqli_close($link);
+?>
+--EXPECT--
+string(6) "foobar"