Annotation of embedaddon/php/ext/mysql/tests/mysql_trace_mode.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: mysql.trace_mode=1
3: --SKIPIF--
4: <?php
5: require_once('skipif.inc');
6: require_once('skipifconnectfailure.inc');
7: ?>
8: --INI--
9: mysql.trace_mode=1
10: error_reporting=E_ALL | E_NOTICE | E_STRICT
11: --FILE--
12: <?php
13: require_once('table.inc');
14:
15: $res1 = mysql_query('SELECT id FROM test', $link);
16:
17: if (!$res2 = @mysql_db_query($db, 'SELECT id FROM test', $link))
18: printf("[001] [%d] %s\n", mysql_errno($link), mysql_error($link));
19: mysql_free_result($res2);
20: print @mysql_escape_string("I don't mind character sets, do I?\n");
21:
22: $res3 = mysql_query('BOGUS_SQL', $link);
23: mysql_close($link);
24:
25: print "done!\n";
26: ?>
27: --CLEAN--
28: <?php
29: require_once("clean_table.inc");
30: ?>
31: --EXPECTF--
32: I don\'t mind character sets, do I?\n
33: Warning: mysql_query(): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'BOGUS_SQL' at line 1 in %s on line %d
34: done!
35:
36: Warning: Unknown: 1 result set(s) not freed. Use mysql_free_result to free result sets which were requested using mysql_query() in %s on line %d
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>