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

Test Failure Report for ext/oci8/tests/field_funcs1.phpt ('oci_field_*() family: error cases')

Script

1: <?php
2:
3:
require(dirname(__FILE__)."/connect.inc");
4:
5:
// Initialize
6:
7:
$stmtarray = array(
8:     
"drop table field_funcs1_tab",
9:     
"create table field_funcs1_tab (id number, value number)",
10:     
"insert into field_funcs1_tab (id, value) values (1,1)",
11:     
"insert into field_funcs1_tab (id, value) values (1,1)",
12:     
"insert into field_funcs1_tab (id, value) values (1,1)"
13:
);
14:
15:
oci8_test_sql_execute($c$stmtarray);
16:
17:
// Run Test
18:
19:
if (!($s oci_parse($c"select * from field_funcs1_tab"))) {
20:     die(
"oci_parse(select) failed!\n");
21: }
22:
23: if (!
oci_execute($s)) {
24:     die(
"oci_execute(select) failed!\n");
25: }
26:
27:
$row oci_fetch_array($sOCI_NUM OCI_RETURN_NULLS OCI_RETURN_LOBS);
28:
var_dump($row);
29:
30: echo 
"Test 1\n";
31:
var_dump(oci_field_is_null($s, -1));
32:
var_dump(oci_field_name($s, -1));
33:
var_dump(oci_field_type($s, -1));
34:
var_dump(oci_field_type_raw($s, -1));
35:
var_dump(oci_field_scale($s, -1));
36:
var_dump(oci_field_precision($s, -1));
37:
var_dump(oci_field_size($s, -1));
38:
39: echo 
"Test 2\n";
40:
var_dump(oci_field_is_null($s"none"));
41:
var_dump(oci_field_name($s"none"));
42:
var_dump(oci_field_type($s"none"));
43:
var_dump(oci_field_type_raw($s"none"));
44:
var_dump(oci_field_scale($s"none"));
45:
var_dump(oci_field_precision($s"none"));
46:
var_dump(oci_field_size($s"none"));
47:
48: echo 
"Test 3\n";
49:
var_dump(oci_field_is_null($c, -1));
50:
var_dump(oci_field_name($c, -1));
51:
var_dump(oci_field_type($c, -1));
52:
var_dump(oci_field_type_raw($c, -1));
53:
var_dump(oci_field_scale($c, -1));
54:
var_dump(oci_field_precision($c, -1));
55:
var_dump(oci_field_size($c, -1));
56:
57: echo 
"Test 4\n";
58:
var_dump(oci_field_is_null($s, array()));
59:
var_dump(oci_field_name($s, array()));
60:
var_dump(oci_field_type($s, array()));
61:
var_dump(oci_field_type_raw($s, array()));
62:
var_dump(oci_field_scale($s, array()));
63:
var_dump(oci_field_precision($s, array()));
64:
var_dump(oci_field_size($s, array()));
65:
66:
var_dump(oci_field_size($s));
67:
68:
69:
// Cleanup
70:
71:
$stmtarray = array(
72:     
"drop table field_funcs1_tab"
73:
);
74:
75:
oci8_test_sql_execute($c$stmtarray);
76:
77: echo 
"Done\n";
78:
79:
?>
80:

Expected

array(2) {
  [0]=>
  string(1) "1"
  [1]=>
  string(1) "1"
}
Test 1

Warning: oci_field_is_null(): Invalid column index "-1" in %s on line %d
bool(false)

Warning: oci_field_name(): Invalid column index "-1" in %s on line %d
bool(false)

Warning: oci_field_type(): Invalid column index "-1" in %s on line %d
bool(false)

Warning: oci_field_type_raw(): Invalid column index "-1" in %s on line %d
bool(false)

Warning: oci_field_scale(): Invalid column index "-1" in %s on line %d
bool(false)

Warning: oci_field_precision(): Invalid column index "-1" in %s on line %d
bool(false)

Warning: oci_field_size(): Invalid column index "-1" in %s on line %d
bool(false)
Test 2

Warning: oci_field_is_null(): Invalid column name "none" in %s on line %d
bool(false)

Warning: oci_field_name(): Invalid column name "none" in %s on line %d
bool(false)

Warning: oci_field_type(): Invalid column name "none" in %s on line %d
bool(false)

Warning: oci_field_type_raw(): Invalid column name "none" in %s on line %d
bool(false)

Warning: oci_field_scale(): Invalid column name "none" in %s on line %d
bool(false)

Warning: oci_field_precision(): Invalid column name "none" in %s on line %d
bool(false)

Warning: oci_field_size(): Invalid column name "none" in %s on line %d
bool(false)
Test 3

Warning: oci_field_is_null(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)

Warning: oci_field_name(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)

Warning: oci_field_type(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)

Warning: oci_field_type_raw(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)

Warning: oci_field_scale(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)

Warning: oci_field_precision(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)

Warning: oci_field_size(): supplied resource is not a valid oci8 statement resource in %s on line %d
bool(false)
Test 4

Warning: oci_field_is_null(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_name(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_type(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_type_raw(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_scale(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_precision(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_size(): Invalid column index "0" in %s on line %d
bool(false)

Warning: oci_field_size() expects exactly 2 parameters, 1 given in %s on line %d
bool(false)
Done

Output

***********************************************************************
Fatal NI connect error 12541, connecting to:
 (DESCRIPTION=(CONNECT_DATA=(SERVICE_NAME=XE)(CID=(PROGRAM=php)(HOST=nex2.php.net)(USER=nlopess)))(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521)))

  VERSION INFORMATION:
	TNS for Linux: Version 11.2.0.2.0 - Beta
	TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.2.0 - Beta
  Time: 17-JUN-2018 05:41:42
  Tracing not turned on.
  Tns error struct:
    ns main err code: 12541
    TNS-12541: TNS:no listener
    ns secondary err code: 12560
    nt main err code: 511
    TNS-00511: No listener

Fatal error: connect.inc: Failed to connect as 'system' to 'localhost/XE': ORA-12541: TNS:no listener in /var/php_gcov/PHP_HEAD/ext/oci8/tests/connect.inc on line 14
    nt secondary err code: 111
    nt OS err code: 0

Diff

001+ ***********************************************************************
002+ Fatal NI connect error 12541, connecting to:
003+  (DESCRIPTION=(CONNECT_DATA=(SERVICE_NAME=XE)(CID=(PROGRAM=php)(HOST=nex2.php.net)(USER=nlopess)))(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521)))
001- array(2) {
002-   [0]=>
003-   string(1) "1"
004-   [1]=>
005-   string(1) "1"
006- }
007- Test 1
005+   VERSION INFORMATION:
006+ 	TNS for Linux: Version 11.2.0.2.0 - Beta
007+ 	TCP/IP NT Protocol Adapter for Linux: Version 11.2.0.2.0 - Beta
008+   Time: 17-JUN-2018 05:41:42
009+   Tracing not turned on.
010+   Tns error struct:
011+     ns main err code: 12541
012+     TNS-12541: TNS:no listener
013+     ns secondary err code: 12560
014+     nt main err code: 511
015+     TNS-00511: No listener
009- Warning: oci_field_is_null(): Invalid column index "-1" in %s on line %d
010- bool(false)
012- Warning: oci_field_name(): Invalid column index "-1" in %s on line %d
013- bool(false)
014- 
017+ Fatal error: connect.inc: Failed to connect as 'system' to 'localhost/XE': ORA-12541: TNS:no listener in /var/php_gcov/PHP_HEAD/ext/oci8/tests/connect.inc on line 14
018+     nt secondary err code: 111
019+     nt OS err code: 0
015- Warning: oci_field_type(): Invalid column index "-1" in %s on line %d
016- bool(false)
017- 
018- Warning: oci_field_type_raw(): Invalid column index "-1" in %s on line %d
019- bool(false)
020- 
021- Warning: oci_field_scale(): Invalid column index "-1" in %s on line %d
022- bool(false)
023- 
024- Warning: oci_field_precision(): Invalid column index "-1" in %s on line %d
025- bool(false)
026- 
027- Warning: oci_field_size(): Invalid column index "-1" in %s on line %d
028- bool(false)
029- Test 2
030- 
031- Warning: oci_field_is_null(): Invalid column name "none" in %s on line %d
032- bool(false)
033- 
034- Warning: oci_field_name(): Invalid column name "none" in %s on line %d
035- bool(false)
036- 
037- Warning: oci_field_type(): Invalid column name "none" in %s on line %d
038- bool(false)
039- 
040- Warning: oci_field_type_raw(): Invalid column name "none" in %s on line %d
041- bool(false)
042- 
043- Warning: oci_field_scale(): Invalid column name "none" in %s on line %d
044- bool(false)
045- 
046- Warning: oci_field_precision(): Invalid column name "none" in %s on line %d
047- bool(false)
048- 
049- Warning: oci_field_size(): Invalid column name "none" in %s on line %d
050- bool(false)
051- Test 3
052- 
053- Warning: oci_field_is_null(): supplied resource is not a valid oci8 statement resource in %s on line %d
054- bool(false)
055- 
056- Warning: oci_field_name(): supplied resource is not a valid oci8 statement resource in %s on line %d
057- bool(false)
058- 
059- Warning: oci_field_type(): supplied resource is not a valid oci8 statement resource in %s on line %d
060- bool(false)
061- 
062- Warning: oci_field_type_raw(): supplied resource is not a valid oci8 statement resource in %s on line %d
063- bool(false)
064- 
065- Warning: oci_field_scale(): supplied resource is not a valid oci8 statement resource in %s on line %d
066- bool(false)
067- 
068- Warning: oci_field_precision(): supplied resource is not a valid oci8 statement resource in %s on line %d
069- bool(false)
070- 
071- Warning: oci_field_size(): supplied resource is not a valid oci8 statement resource in %s on line %d
072- bool(false)
073- Test 4
074- 
075- Warning: oci_field_is_null(): Invalid column index "0" in %s on line %d
076- bool(false)
077- 
078- Warning: oci_field_name(): Invalid column index "0" in %s on line %d
079- bool(false)
080- 
081- Warning: oci_field_type(): Invalid column index "0" in %s on line %d
082- bool(false)
083- 
084- Warning: oci_field_type_raw(): Invalid column index "0" in %s on line %d
085- bool(false)
086- 
087- Warning: oci_field_scale(): Invalid column index "0" in %s on line %d
088- bool(false)
089- 
090- Warning: oci_field_precision(): Invalid column index "0" in %s on line %d
091- bool(false)
092- 
093- Warning: oci_field_size(): Invalid column index "0" in %s on line %d
094- bool(false)
095- 
096- Warning: oci_field_size() expects exactly 2 parameters, 1 given in %s on line %d
097- bool(false)
098- Done

 

Generated at Mon, 18 Jun 2018 17:33:50 +0000 (24 hours ago)

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