Test: /ext/oci8/tests/bug42841.phpt - Version 5.4.30        

Bug #42841 oci_new_cursor PHP crash
Submitted: 2007-10-03 15:39:01 Modified: 2008-01-31 00:38:09
From: pr0head Assigned:
Status: Closed Package: OCI8 related
PHP Version: 5.2.4 OS: Linux version 2.6.20-gentoo-r8

There is 1 diff reported by users for this test.

Count Diff
2 (100%)
001+ Warning: oci_connect(): ORA-12541: TNS:no listener in %s/bug42841.php on line 6
002+
003+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 52
004+
005+ Warning: oci_error() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 54
006+ create or replace procedure bug42841_proc(out_1 out sys_refcursor) is
007+ begin
008+ open out_1 for select 11 from dual union all select 12 from dual union all select 13 from dual;
009+ end bug42841_proc;
010+
011+
012+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 52
013+
014+ Warning: oci_error() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 54
015+ create or replace package bug43449_pkg is
016+ type cursortype is ref Cursor;
017+ function testcursor return cursortype;
018+ end bug43449_pkg;
019+
020+
021+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 52
022+
023+ Warning: oci_error() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 54
024+ create or replace package body bug43449_pkg is
025+ function testcursor return cursortype is
026+ retCursor cursorType;
027+ begin
028+ Open retCursor For 'select * from dual';
029+ return retCursor;
030+ end;
031+ end bug43449_pkg;
032+
033+ Test bug 42841: Procedure with OUT cursor parameter
034+ First attempt
035+
036+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 40
037+
038+ Warning: oci_new_cursor() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 41
039+
040+ Warning: oci_bind_by_name() expects parameter 1 to be resource, null given in %s/bug42841.php on line 42
041+
042+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 44
043+
044+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 45
045+
046+ Warning: oci_fetch_array() expects parameter 1 to be resource, null given in %s/bug42841.php on line 47
047+
048+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 51
049+
050+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 52
051+
052+ Notice: Undefined variable: data1 in %s/bug42841.php on line 53
053+ NULL
001- Test bug 42841: Procedure with OUT cursor parameter
002- First attempt
003- array(3) {
004- [0]=>
005- array(1) {
006- [11]=>
007- string(2) "11"
008- }
009- [1]=>
010- array(1) {
011- [11]=>
012- string(2) "12"
013- }
014- [2]=>
015- array(1) {
016- [11]=>
017- string(2) "13"
018- }
019- }
020- Second attempt
021- array(3) {
022- [0]=>
023- array(1) {
024- [11]=>
025- string(2) "11"
026- }
027- [1]=>
028- array(1) {
029- [11]=>
030- string(2) "12"
031- }
032- [2]=>
033- array(1) {
034- [11]=>
035- string(2) "13"
036- }
037- }
038- Test bug 43449: Cursor as function result
039- array(1) {
040- [0]=>
041- array(1) {
042- ["DUMMY"]=>
043- string(1) "X"
044- }
045- }
046- array(1) {
047- [0]=>
048- array(1) {
049- ["DUMMY"]=>
050- string(1) "X"
051- }
052- }
053- Done
054+ Second attempt
055+
056+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 58
057+
058+ Warning: oci_new_cursor() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 59
059+
060+ Warning: oci_bind_by_name() expects parameter 1 to be resource, null given in %s/bug42841.php on line 60
061+
062+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 62
063+
064+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 63
065+
066+ Warning: oci_fetch_array() expects parameter 1 to be resource, null given in %s/bug42841.php on line 65
067+
068+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 69
069+
070+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 70
071+
072+ Notice: Undefined variable: data2 in %s/bug42841.php on line 71
073+ NULL
074+
075+ Warning: oci_new_connect(): ORA-12541: TNS:no listener in %s/bug42841.php on line 104
076+ Test bug 43449: Cursor as function result
077+
078+ Warning: oci_new_cursor() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 84
079+
080+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 85
081+
082+ Warning: oci_bind_by_name() expects parameter 1 to be resource, null given in %s/bug42841.php on line 86
083+
084+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 87
085+
086+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 88
087+
088+ Warning: ocifetchinto() expects parameter 1 to be resource, null given in %s/bug42841.php on line 92
089+
090+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 96
091+
092+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 97
093+ array(0) {
094+ }
095+
096+ Warning: oci_new_cursor() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 84
097+
098+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in %s/bug42841.php on line 85
099+
100+ Warning: oci_bind_by_name() expects parameter 1 to be resource, null given in %s/bug42841.php on line 86
101+
102+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 87
103+
104+ Warning: oci_execute() expects parameter 1 to be resource, null given in %s/bug42841.php on line 88
105+
106+ Warning: ocifetchinto() expects parameter 1 to be resource, null given in %s/bug42841.php on line 92
107+
108+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 96
109+
110+ Warning: oci_free_statement() expects parameter 1 to be resource, null given in %s/bug42841.php on line 97
111+ array(0) {
112+ }
113+
114+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 52
115+
116+ Warning: oci_error() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 54
117+ drop procedure bug42841_proc
118+
119+
120+ Warning: oci_parse() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 52
121+
122+ Warning: oci_error() expects parameter 1 to be resource, boolean given in /usr/local/src/php-5.4.30/ext/oci8/tests/details.inc on line 54
123+ drop package bug43449_pkg
124+
125+ Done