ID:               31898
 User updated by:  buhmann at teqneers dot de
 Reported By:      buhmann at teqneers dot de
 Status:           Open
 Bug Type:         Feature/Change Request
 Operating System: WIN2k/Win2003/XP
 PHP Version:      4.3.10
 New Comment:

again one month later, nothing happens :-(


Previous Comments:
------------------------------------------------------------------------

[2005-03-01 11:00:14] buhmann at teqneers dot de

Is anybody in here, which is responsible for this or can make a
conclusion to this???

------------------------------------------------------------------------

[2005-02-09 15:45:24] buhmann at teqneers dot de

Description:
------------
I have to fight with the same problem up to the current release
(4.9.10). It doesn't seems to be fixed. In my opinion adding more
tnsnames to the oracle client isn't help enough. the oracle user have
to be enough.

I tried it on a win2k and win2003 server edition with oracle clients 8
and 9. always the same problem. opening the first connection works
fine. also doing some selects with this connection. but, after opening
a second connection and don't use it immediately, errors occurred. if i
instead use the second connection immediately (doing a select or
anything), it will also works correct. The errors will occurr (using
the first connection) until i will use the second connection.

Reproduce code:
---------------
<?php
        /* 
           test table 1, created on the first schema 'SCHEMA_1'
           ----------------------------
           create table test1 ( 
           dummy NUMBER(20) NOT NULL
                                 );  
           commit;
           ----------------------------
           
           test table 2, created on the second schema 'SCHEMA_2'
           ----------------------------
           create table test2 ( 
           dummy NUMBER(20) NOT NULL
                                 ); 
           commit;
           ----------------------------
        */

        function selectOne() { 
                global $connectionOne;
                
                $select         = 'SELECT * FROM test1';
                $stmt           = OCIPARSE( $connectionOne, $select );
                OCIExecute( $stmt );
                OCIFetchInto( $stmt, $arr, OCI_ASSOC );
                OCIFreeStatement( $stmt );     
        }
        
        function selectTwo() { 
                global $connectionTwo;
                
                $select         = 'SELECT * FROM test2';
                $stmt           = OCIPARSE( $connectionTwo, $select );
                OCIExecute( $stmt );
                OCIFetchInto( $stmt, $arr, OCI_ASSOC );
                OCIFreeStatement( $stmt );     
        }
        
        
        // make first connection
        $connectionOne = OCILogon( 'user1', 'pwd1', 'TNS' );
        
        
        // select again from table test1 (connection 1)
        echo '
        Start----- Test1 Con1 -----------------------<br />';
                selectOne();
        echo '
        End-------------------------------------------
        <br />
        <br />
        <br />';
        
        
        // make second connection
        $connectionTwo = OCILogon( 'user2', 'pwd2', 'TNS' );
        
        
        // select again from table test1 (connection 1), this will result in
an error
        echo '
        Start----- Test1 Con1 -----------------------<br />';
                selectOne();
// ===> if you will make a selectTwo() instead off a
// ===> selectOne() at this point, now errors occurr!
                //selectTwo();
        echo '
        End-------------------------------------------
        <br />
        <br />
        <br />';
        
        
        
        
        
        // select from table test1 (connection 1)
        echo '
        Start----- Test1 Con1 -----------------------<br />';
                selectOne();
        echo '
        End-------------------------------------------
        <br />
        <br />
        <br />';
        
        
        // select from table test2 (connection 2)
        echo '
        Start----- Test2 Con2 -----------------------<br />';
                selectTwo();
        echo '
        End-------------------------------------------
        <br />
        <br />
        <br />';
        
        
        // select again from table test1 (connection 1), this will work now
        echo '
        Start----- Test1 Con1 -----------------------<br />';
                selectOne();
        echo '
        End-------------------------------------------
        <br />
        <br />
        <br />';
?>



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=31898&edit=1

Reply via email to