Lines Matching refs:mysqli
2 mysqli->fetch_array()
4 mysqli
17 if (!$mysqli = new my_mysqli($host, $user, $passwd, $db, $port, $socket))
21 if (!$res = $mysqli->query("SELECT * FROM test ORDER BY id LIMIT 5")) {
22 printf("[004] [%d] %s\n", $mysqli->errno, $mysqli->error);
42 if (!$res = $mysqli->query("SELECT 1 AS a, 2 AS a, 3 AS c, 4 AS C, NULL AS d, true AS e")) {
43 printf("[010] Cannot run query, [%d] %s\n", $mysqli->errno, $$mysqli->error);
49 if (!$res = $mysqli->query("SELECT 1 AS a, 2 AS b, 3 AS c, 4 AS C")) {
51 $mysqli->errno, $$mysqli->error);
58 // NOTE: for BC reasons with ext/mysql, ext/mysqli accepts invalid result modes.
73 …function func_mysqli_fetch_array($mysqli, $engine, $sql_type, $sql_value, $php_value, $offset, $re…
75 if (!$mysqli->query("DROP TABLE IF EXISTS test")) {
76 printf("[%04d] [%d] %s\n", $offset, $mysqli->errno, $mysqli->error);
80 …if (!$mysqli->query($sql = sprintf("CREATE TABLE test(id INT NOT NULL, label %s, PRIMARY KEY(id)) …
86 if (!$mysqli->query($sql = sprintf("INSERT INTO test(id, label) VALUES (1, NULL)"))) {
87 printf("[%04d] [%d] %s\n", $offset + 1, $mysqli->errno, $mysqli->error);
92 … if (!$mysqli->query($sql = "INSERT INTO test(id, label) VALUES (1, '" . $sql_value . "')")) {
93 … printf("[%04ds] [%d] %s - %s\n", $offset + 1, $mysqli->errno, $mysqli->error, $sql);
97 … if (!$mysqli->query($sql = sprintf("INSERT INTO test(id, label) VALUES (1, '%d')", $sql_value))) {
98 printf("[%04di] [%d] %s\n", $offset + 1, $mysqli->errno, $mysqli->error);
104 if (!$res = $mysqli->query("SELECT id, label FROM test")) {
105 printf("[%04d] [%d] %s\n", $offset + 2, $mysqli->errno, $mysqli->error);
110 printf("[%04d] [%d] %s\n", $offset + 3, $mysqli->errno, $mysqli->error);
121 gettype($row['label']), $row['label'], $mysqli->errno, $mysqli->error);
129 gettype($row['label']), $row['label'], $mysqli->errno, $mysqli->error);
146 func_mysqli_fetch_array($mysqli, $engine, "TINYINT", -11, "-11", 20);
147 func_mysqli_fetch_array($mysqli, $engine, "TINYINT", NULL, NULL, 30);
148 func_mysqli_fetch_array($mysqli, $engine, "TINYINT UNSIGNED", 1, "1", 40);
149 func_mysqli_fetch_array($mysqli, $engine, "TINYINT UNSIGNED", NULL, NULL, 50);
151 func_mysqli_fetch_array($mysqli, $engine, "BOOL", 1, "1", 60);
152 func_mysqli_fetch_array($mysqli, $engine, "BOOL", NULL, NULL, 70);
153 func_mysqli_fetch_array($mysqli, $engine, "BOOLEAN", 0, "0", 80);
154 func_mysqli_fetch_array($mysqli, $engine, "BOOLEAN", NULL, NULL, 90);
156 func_mysqli_fetch_array($mysqli, $engine, "SMALLINT", -32768, "-32768", 100);
157 func_mysqli_fetch_array($mysqli, $engine, "SMALLINT", 32767, "32767", 110);
158 func_mysqli_fetch_array($mysqli, $engine, "SMALLINT", NULL, NULL, 120);
159 func_mysqli_fetch_array($mysqli, $engine, "SMALLINT UNSIGNED", 65535, "65535", 130);
160 func_mysqli_fetch_array($mysqli, $engine, "SMALLINT UNSIGNED", NULL, NULL, 140);
162 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMINT", -8388608, "-8388608", 150);
163 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMINT", 8388607, "8388607", 160);
164 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMINT", NULL, NULL, 170);
165 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMINT UNSIGNED", 16777215, "16777215", 180);
166 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMINT UNSIGNED", NULL, NULL, 190);
168 func_mysqli_fetch_array($mysqli, $engine, "INTEGER", -2147483648, "-2147483648", 200);
169 func_mysqli_fetch_array($mysqli, $engine, "INTEGER", 2147483647, "2147483647", 210);
170 func_mysqli_fetch_array($mysqli, $engine, "INTEGER", NULL, NULL, 220);
171 func_mysqli_fetch_array($mysqli, $engine, "INTEGER UNSIGNED", "4294967295", "4294967295", 230);
172 func_mysqli_fetch_array($mysqli, $engine, "INTEGER UNSIGNED", NULL, NULL, 240);
174 …func_mysqli_fetch_array($mysqli, $engine, "BIGINT", "-9223372036854775808", "-9223372036854775808"…
175 func_mysqli_fetch_array($mysqli, $engine, "BIGINT", NULL, NULL, 260);
176 …func_mysqli_fetch_array($mysqli, $engine, "BIGINT UNSIGNED", "18446744073709551615", "184467440737…
177 func_mysqli_fetch_array($mysqli, $engine, "BIGINT UNSIGNED", NULL, NULL, 280);
179 …func_mysqli_fetch_array($mysqli, $engine, "FLOAT", (string)(-9223372036854775808 - 1.1), "-9.22337…
180 func_mysqli_fetch_array($mysqli, $engine, "FLOAT", NULL, NULL, 300);
181 …func_mysqli_fetch_array($mysqli, $engine, "FLOAT UNSIGNED", (string)(18446744073709551615 + 1.1), …
182 func_mysqli_fetch_array($mysqli, $engine, "FLOAT UNSIGNED ", NULL, NULL, 320);
184 func_mysqli_fetch_array($mysqli, $engine, "DOUBLE(10,2)", "-99999999.99", "-99999999.99", 330);
185 func_mysqli_fetch_array($mysqli, $engine, "DOUBLE(10,2)", NULL, NULL, 340);
186 …func_mysqli_fetch_array($mysqli, $engine, "DOUBLE(10,2) UNSIGNED", "99999999.99", "99999999.99", 3…
187 func_mysqli_fetch_array($mysqli, $engine, "DOUBLE(10,2) UNSIGNED", NULL, NULL, 360);
188 func_mysqli_fetch_array($mysqli, $engine, "DECIMAL(10,2)", "-99999999.99", "-99999999.99", 370);
189 func_mysqli_fetch_array($mysqli, $engine, "DECIMAL(10,2)", NULL, NULL, 380);
190 func_mysqli_fetch_array($mysqli, $engine, "DECIMAL(10,2)", "99999999.99", "99999999.99", 390);
191 func_mysqli_fetch_array($mysqli, $engine, "DECIMAL(10,2)", NULL, NULL, 400);
195 func_mysqli_fetch_array($mysqli, $engine, "DATE",$date, $date, 410);
196 func_mysqli_fetch_array($mysqli, $engine, "DATE NOT NULL",$date, $date, 420);
197 func_mysqli_fetch_array($mysqli, $engine, "DATE", NULL, NULL, 430);
200 func_mysqli_fetch_array($mysqli, $engine, "DATETIME", $date, $date, 440);
201 func_mysqli_fetch_array($mysqli, $engine, "DATETIME NOT NULL", $date, $date, 450);
202 func_mysqli_fetch_array($mysqli, $engine, "DATETIME", NULL, NULL, 460);
203 func_mysqli_fetch_array($mysqli, $engine, "TIMESTAMP", $date, $date, 470);
205 func_mysqli_fetch_array($mysqli, $engine, "TIME", $date, $date, 480);
206 func_mysqli_fetch_array($mysqli, $engine, "TIME NOT NULL", $date, $date, 490);
207 func_mysqli_fetch_array($mysqli, $engine, "TIME", NULL, NULL, 500);
208 func_mysqli_fetch_array($mysqli, $engine, "YEAR", @date('Y'), @date('Y'), 510);
209 func_mysqli_fetch_array($mysqli, $engine, "YEAR NOT NULL", @date('Y'), @date('Y'), 520);
210 func_mysqli_fetch_array($mysqli, $engine, "YEAR", NULL, NULL, 530);
213 func_mysqli_fetch_array($mysqli, $engine, "CHAR(1)", "a", "a", 540);
214 func_mysqli_fetch_array($mysqli, $engine, "CHAR(255)", $string255, $string255, 550);
215 func_mysqli_fetch_array($mysqli, $engine, "CHAR(1) NOT NULL", "a", "a", 560);
216 func_mysqli_fetch_array($mysqli, $engine, "CHAR(1)", NULL, NULL, 570);
219 func_mysqli_fetch_array($mysqli, $engine, "VARCHAR(1)", "a", "a", 580);
220 func_mysqli_fetch_array($mysqli, $engine, "VARCHAR(255)", $string255, $string255, 590);
221 func_mysqli_fetch_array($mysqli, $engine, "VARCHAR(65400)", $string65k, $string65k, 600);
222 func_mysqli_fetch_array($mysqli, $engine, "VARCHAR(1) NOT NULL", "a", "a", 610);
223 func_mysqli_fetch_array($mysqli, $engine, "VARCHAR(1)", NULL, NULL, 620);
225 func_mysqli_fetch_array($mysqli, $engine, "BINARY(1)", "a", "a", 630);
226 func_mysqli_fetch_array($mysqli, $engine, "BINARY(2)", chr(0) . "a", chr(0) . "a", 640);
227 func_mysqli_fetch_array($mysqli, $engine, "BINARY(1) NOT NULL", "b", "b", 650);
228 func_mysqli_fetch_array($mysqli, $engine, "BINARY(1)", NULL, NULL, 660);
230 func_mysqli_fetch_array($mysqli, $engine, "VARBINARY(1)", "a", "a", 670);
231 func_mysqli_fetch_array($mysqli, $engine, "VARBINARY(2)", chr(0) . "a", chr(0) . "a", 680);
232 func_mysqli_fetch_array($mysqli, $engine, "VARBINARY(1) NOT NULL", "b", "b", 690);
233 func_mysqli_fetch_array($mysqli, $engine, "VARBINARY(1)", NULL, NULL, 700);
235 func_mysqli_fetch_array($mysqli, $engine, "TINYBLOB", "a", "a", 710);
236 func_mysqli_fetch_array($mysqli, $engine, "TINYBLOB", chr(0) . "a", chr(0) . "a", 720);
237 func_mysqli_fetch_array($mysqli, $engine, "TINYBLOB NOT NULL", "b", "b", 730);
238 func_mysqli_fetch_array($mysqli, $engine, "TINYBLOB", NULL, NULL, 740);
240 func_mysqli_fetch_array($mysqli, $engine, "TINYTEXT", "a", "a", 750);
241 func_mysqli_fetch_array($mysqli, $engine, "TINYTEXT NOT NULL", "a", "a", 760);
242 func_mysqli_fetch_array($mysqli, $engine, "TINYTEXT", NULL, NULL, 770);
244 func_mysqli_fetch_array($mysqli, $engine, "BLOB", "a", "a", 780);
245 func_mysqli_fetch_array($mysqli, $engine, "BLOB", chr(0) . "a", chr(0) . "a", 780);
246 func_mysqli_fetch_array($mysqli, $engine, "BLOB", NULL, NULL, 790);
248 func_mysqli_fetch_array($mysqli, $engine, "TEXT", "a", "a", 800);
249 func_mysqli_fetch_array($mysqli, $engine, "TEXT", chr(0) . "a", chr(0) . "a", 810);
250 func_mysqli_fetch_array($mysqli, $engine, "TEXT", NULL, NULL, 820);
252 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMBLOB", "a", "a", 830);
253 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMBLOB", chr(0) . "a", chr(0) . "a", 840);
254 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMBLOB", NULL, NULL, 850);
256 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMTEXT", "a", "a", 860);
257 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMTEXT", chr(0) . "a", chr(0) . "a", 870);
258 func_mysqli_fetch_array($mysqli, $engine, "MEDIUMTEXT", NULL, NULL, 880);
260 func_mysqli_fetch_array($mysqli, $engine, "LONGBLOB", "a", "a", 890);
261 func_mysqli_fetch_array($mysqli, $engine, "LONGTEXT", chr(0) . "a", chr(0) . "a", 900);
262 func_mysqli_fetch_array($mysqli, $engine, "LONGBLOB", NULL, NULL, 910);
264 func_mysqli_fetch_array($mysqli, $engine, "ENUM('a', 'b')", "a", "a", 920);
265 func_mysqli_fetch_array($mysqli, $engine, "ENUM('a', 'b')", NULL, NULL, 930);
267 func_mysqli_fetch_array($mysqli, $engine, "SET('a', 'b')", "a", "a", 940);
268 func_mysqli_fetch_array($mysqli, $engine, "SET('a', 'b')", NULL, NULL, 950);
270 $mysqli->close();