Lines Matching refs:db
14 $db = pg_connect($conn_str);
16 $version = pg_version($db);
22 $db_socket = pg_socket($db);
25 $nb_send = pg_send_prepare($db, 'php_test', "SELECT * FROM ".$table_name." WHERE num > \$1;");
29 nb_flush($db, $db_socket);
32 nb_consume($db, $db_socket);
34 if (!($result = pg_get_result($db))) {
39 $nb_send = pg_send_execute($db, 'php_test', array(100));
43 nb_flush($db, $db_socket);
46 nb_consume($db, $db_socket);
48 if (!($result = pg_get_result($db))) {
68 pg_num_rows(pg_query_params($db, "SELECT * FROM ".$table_name." WHERE num > \$1;", array(100)));
69 pg_num_fields(pg_query_params($db, "SELECT * FROM ".$table_name." WHERE num > \$1;", array(100)));
77 $nb_send = pg_send_prepare($db, "php_test2", "INSERT INTO ".$table_name." VALUES (\$1, \$2);");
81 nb_flush($db, $db_socket);
84 nb_consume($db, $db_socket);
86 if (!($result = pg_get_result($db))) {
91 $nb_send = pg_send_execute($db, "php_test2", array(9999, "A'BC"));
95 nb_flush($db, $db_socket);
98 nb_consume($db, $db_socket);
100 if (!($result = pg_get_result($db))) {
106 pg_close($db);