PHP  
 PHP_5_4
downloads | QA | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | my php.net 
 

Test Failure Report for ext/odbc/tests/odbc_free_result_001.phpt ('odbc_free_result(): Basic test')

Script

1: <?php
2:
3:
include 'config.inc';
4:
5:
$conn odbc_connect($dsn$user$pass);
6:
7:
odbc_exec($conn'CREATE DATABASE odbcTEST');
8:
9:
odbc_exec($conn'CREATE TABLE FOO (TEST INT)');
10:
odbc_exec($conn'ALTER TABLE FOO ADD PRIMARY KEY (TEST)');
11:
12:
odbc_exec($conn'INSERT INTO FOO VALUES (1)');
13:
odbc_exec($conn'INSERT INTO FOO VALUES (2)');
14:
15:
$res odbc_exec($conn'SELECT * FROM FOO');
16:
17:
var_dump(odbc_fetch_row($res));
18:
var_dump(odbc_result($res'test'));
19:
var_dump(odbc_free_result($res));
20:
var_dump(odbc_free_result($conn));
21:
var_dump(odbc_free_result(NULL));
22:
var_dump(odbc_fetch_row($res));
23:
var_dump(odbc_result($res'test'));
24:
25:
odbc_exec($conn'DROP TABLE FOO');
26:
27:
odbc_exec($conn'DROP DATABASE odbcTEST');
28:
29:
?>
30:

Expected

bool(true)
string(1) "1"
bool(true)

Warning: odbc_free_result(): supplied resource is not a valid ODBC result resource in %s on line %d
bool(false)

Warning: odbc_free_result() expects parameter 1 to be resource, null given in %s on line %d
NULL

Warning: odbc_fetch_row(): %d is not a valid ODBC result resource in %s on line %d
bool(false)

Warning: odbc_result(): %d is not a valid ODBC result resource in %s on line %d
bool(false)

Output

Warning: odbc_exec(): SQL error: [unixODBC][MySQL][ODBC 5.1 Driver][mysqld-5.1.73]Access denied for user 'odbcUser'@'localhost' to database 'odbcTEST', SQL state S1000 in SQLExecDirect in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 7
bool(true)
string(1) "1"
bool(true)

Warning: odbc_free_result(): supplied resource is not a valid ODBC result resource in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 20
bool(false)

Warning: odbc_free_result() expects parameter 1 to be resource, null given in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 21
NULL

Warning: odbc_fetch_row(): 10 is not a valid ODBC result resource in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 22
bool(false)

Warning: odbc_result(): 10 is not a valid ODBC result resource in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 23
bool(false)

Warning: odbc_exec(): SQL error: [unixODBC][MySQL][ODBC 5.1 Driver][mysqld-5.1.73]Access denied for user 'odbcUser'@'localhost' to database 'odbcTEST', SQL state S1000 in SQLExecDirect in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 27

Diff

001+ Warning: odbc_exec(): SQL error: [unixODBC][MySQL][ODBC 5.1 Driver][mysqld-5.1.73]Access denied for user 'odbcUser'@'localhost' to database 'odbcTEST', SQL state S1000 in SQLExecDirect in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 7
017+ 
018+ Warning: odbc_exec(): SQL error: [unixODBC][MySQL][ODBC 5.1 Driver][mysqld-5.1.73]Access denied for user 'odbcUser'@'localhost' to database 'odbcTEST', SQL state S1000 in SQLExecDirect in /var/php_gcov/PHP_5_4/ext/odbc/tests/odbc_free_result_001.php on line 27

 

Generated at Mon, 29 Sep 2014 14:26:37 +0000 (2 days ago)

Copyright © 2005-2014 The PHP Group
All rights reserved.