php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #28944 OCITypeByName: OCI-21522 with two connections
Submitted: 2004-06-28 11:25 UTC Modified: 2005-09-08 11:47 UTC
Votes:3
Avg. Score:5.0 ± 0.0
Reproduced:2 of 2 (100.0%)
Same Version:1 (50.0%)
Same OS:1 (50.0%)
From: manuel at pincho dot org Assigned: tony2001 (profile)
Status: Closed Package: OCI8 related
PHP Version: 5.*, 4.* OS: Linux
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: manuel at pincho dot org
New email:
PHP Version: OS:

 

 [2004-06-28 11:25 UTC] manuel at pincho dot org
Description:
------------
When I use ocinewcollection and I have to connections or 
more  open in the same php with the same user,password and SID ; ocinewcollection fails with 

Warning: ocinewcollection(): OCITypeByName: OCI-21522: attempted to use an invalid connection in OCI (object mode only)

Oracle version is 9.2.0.4
PHP 4.3.6: './configure' '--with-apache=/usr/local/src/apache_1.3.29' '--with-oci8=/u01/app/oracle/product/9.2.0' '--with-mnogosearch=/usr/local/mnogosearch' 
'--with-mysql' '--with-gd' '--with-jpeg-dir' '--with-png-dir' '--with-zlib-dir' '--enable-track-vars' '--enable-sigchild' '--enable-xml' '--enable-inline-optimization' '--enable-memory-limit' '--disable-debug'


Reproduce code:
---------------
// CREATE OR REPLACE TYPE local_id_array AS TABLE OF NUMBER(11);
$db =OCIPLogon('XXX','XXX','XXX');
$db2=OCIPLogon('XXX','XXX','XXX');
$coll = ocinewcollection ($db2,'LOCAL_ID_ARRAY');


Actual result:
--------------
Warning: ocinewcollection(): OCITypeByName: OCI-21522: attempted to use an invalid connection in OCI (object mode only)

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-08-13 17:48 UTC] tony2001@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip

Please, try with the latest version first.
 [2004-08-17 10:44 UTC] manuel at pincho dot org
I download 
php4-STABLE-200408170630.tar.bz2
and
php5-200408170630.tar.bz2

I execute the example script with the corrent user, pass and    SID.

/usr/local/src/php4-STABLE-200408170630/sapi/cli/php /tmp/x.php

Warning: ocinewcollection(): OCITypeByName: OCI-21522: attempted to use an invalid connection in OCI (object mode only)
 in /tmp/x.php on line 5

and

/usr/local/src/php5-200408170630/sapi/cli/php /tmp/x.php

Warning: ocinewcollection(): OCITypeByName: OCI-21522: attempted to use an invalid connection in OCI (object mode only)
 in /tmp/x.php on line 5

If I make one conection It works.
 [2005-09-08 11:47 UTC] tony2001@php.net
The bug has been fixed in OCI8 v.1.1, which is available in CVS HEAD and PECL (use `pear install oci8-beta` to install it).
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Dec 26 09:01:29 2024 UTC