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/array_bind_date.phpt ('oci_bind_array_by_name() and SQLT_ODT')

Script

1: <?php
2:
3:
require dirname(__FILE__).'/connect.inc';
4:
5:
$drop "DROP table bind_test";
6:
$statement oci_parse($c$drop);
7: @
oci_execute($statement);
8:
9:
$create "CREATE table bind_test(name DATE)";
10:
$statement oci_parse($c$create);
11:
oci_execute($statement);
12:
13:
$create_pkg "
14: CREATE OR REPLACE PACKAGE ARRAY_BIND_DATE_PKG AS 
15:   TYPE ARRTYPE IS TABLE OF DATE INDEX BY BINARY_INTEGER; 
16:   PROCEDURE iobind(c1 IN OUT ARRTYPE); 
17: END ARRAY_BIND_DATE_PKG;"
;
18:
$statement oci_parse($c$create_pkg);
19:
oci_execute($statement);
20:
21:
$create_pkg_body "
22: CREATE OR REPLACE PACKAGE BODY ARRAY_BIND_DATE_PKG AS 
23:   CURSOR CUR IS SELECT name FROM bind_test;
24:   PROCEDURE iobind(c1 IN OUT ARRTYPE) IS
25:     BEGIN
26:     FOR i IN 1..5 LOOP
27:       INSERT INTO bind_test VALUES (c1(i));
28:     END LOOP;
29:     IF NOT CUR%ISOPEN THEN
30:       OPEN CUR;
31:     END IF;
32:     FOR i IN REVERSE 1..5 LOOP
33:       FETCH CUR INTO c1(i);
34:       IF CUR%NOTFOUND THEN
35:         CLOSE CUR;
36:         EXIT;
37:       END IF;
38:     END LOOP;
39:   END iobind;
40: END ARRAY_BIND_DATE_PKG;"
;
41:
$statement oci_parse($c$create_pkg_body);
42:
oci_execute($statement);
43:
44:
$statement oci_parse($c"BEGIN array_bind_date_pkg.iobind(:c1); END;");
45:
46:
$array = Array("06-DEC-05","10-DEC-80","21-AUG-91","26-OCT-17","05-NOV-05");
47:
48:
oci_bind_array_by_name($statement":c1"$array55SQLT_ODT);
49:
50:
oci_execute($statement);
51:
52:
var_dump($array);
53:
54: echo 
"Done\n";
55:
?>
56:

Expected

array(5) {
  [0]=>
  string(9) "05-NOV-05"
  [1]=>
  string(9) "26-OCT-17"
  [2]=>
  string(9) "21-AUG-91"
  [3]=>
  string(9) "10-DEC-80"
  [4]=>
  string(9) "06-DEC-05"
}
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 04:47:59
  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)))
004+ 
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 04:47:59
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
001- array(5) {
002-   [0]=>
003-   string(9) "05-NOV-05"
004-   [1]=>
005-   string(9) "26-OCT-17"
006-   [2]=>
007-   string(9) "21-AUG-91"
008-   [3]=>
009-   string(9) "10-DEC-80"
010-   [4]=>
011-   string(9) "06-DEC-05"
012- }
013- Done
014+     nt main err code: 511
015+     TNS-00511: No listener
016+ 
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

 

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

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