473,399 Members | 3,401 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,399 software developers and data experts.

PHP adodb

I just started using the php adodb library for my Oracle transactions,
but am running into a problem when there are 2 simultaneous requests
going on at the same time.

The nature of the php app that I created is it runs a large query that
takes approximately 15 seconds to run and then prints the data out on
a web page.

If I open 2 separate browser windows and call the same report at about
the same time, or while one report is processing, I get the following
error:

Warning: Unknown: _oci_close_session: OCISessionEnd: ORA-03127: no new
operations allowed until the active operation ends in Unknown on line
0

When I was doing this same report using php4 and the OCI functions I
had no problems with this database and concurrent transactions, seems
to be something with how I am using adodb..

Here is my code snippet:

include('./adodb/adodb.inc.php');
$username = "user"; //oracle user
$password = "password"; //oracle password
$database = "testdatabase"; //tnsnames database entry

//Type of connection
$db = NewADOConnection('oci8');

//Sets the query results to come back as assoc arrays
$db->SetFetchMode(ADODB_FETCH_ASSOC);

function InvokeErrorHandler()
{
global $db; ## assume global
echo $db->ErrorMsg();
}

//Make the connection
$db->Connect($database, $username, $password);
if (!$db->Connect($database, $username, $password))
InvokeErrorHandler();

$query = "SELECT * FROM table";

$rs = $db->Execute($query);

This all seems common, as I have seen many examples using similar
config and connect info, but I cannot get past the concurrent issue, I
have tried using PConnect instead of connect, but I still get
problems.

Thanks

Mar 27 '07 #1
7 3488
On Tue, 27 Mar 2007 09:11:29 -0700, trpost wrote:
I just started using the php adodb library for my Oracle transactions,
but am running into a problem when there are 2 simultaneous requests
going on at the same time.

The nature of the php app that I created is it runs a large query that
takes approximately 15 seconds to run and then prints the data out on a
web page.

If I open 2 separate browser windows and call the same report at about
the same time, or while one report is processing, I get the following
error:

Warning: Unknown: _oci_close_session: OCISessionEnd: ORA-03127: no new
operations allowed until the active operation ends in Unknown on line 0

When I was doing this same report using php4 and the OCI functions I had
no problems with this database and concurrent transactions, seems to be
something with how I am using adodb..

Here is my code snippet:

include('./adodb/adodb.inc.php');
$username = "user"; //oracle user
$password = "password"; //oracle password $database = "testdatabase";
//tnsnames database entry

//Type of connection
$db = NewADOConnection('oci8');

//Sets the query results to come back as assoc arrays
$db->SetFetchMode(ADODB_FETCH_ASSOC);

function InvokeErrorHandler()
{
global $db; ## assume global
echo $db->ErrorMsg();
}

//Make the connection
$db->Connect($database, $username, $password); if
(!$db->Connect($database, $username, $password)) InvokeErrorHandler();

$query = "SELECT * FROM table";

$rs = $db->Execute($query);

This all seems common, as I have seen many examples using similar config
and connect info, but I cannot get past the concurrent issue, I have
tried using PConnect instead of connect, but I still get problems.
Is this a Windows installation of Apache? I have no such problem
with either Linux or Solaris.
Mar 28 '07 #2
I get the same problem on both Windows and Solaris

Apr 2 '07 #3
On Apr 2, 1:38 pm, trp...@gmail.com wrote:
I get the same problem on both Windows and Solaris
Is there anything better than adodb, that supports concurrent
transactions. I am still getting the following if I call the same
query at the same time:

Warning: ocilogon() [function.ocilogon]: OCISessionBegin: ORA-03127:
no new operations allowed until the active operation ends

Apr 2 '07 #4
On 27 Mar 2007 09:11:29 -0700, tr****@gmail.com wrote:
>Warning: Unknown: _oci_close_session: OCISessionEnd: ORA-03127: no new
operations allowed until the active operation ends in Unknown on line
0
What version of PHP and Oracle client?

Does your table contain LOBs? There seem to be a few bugs that result from
problems in LOBs that result in this error.

http://www.google.co.uk/search?q=ORA-03127+oci8

--
Andy Hassall :: an**@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool
Apr 3 '07 #5
On 2 Apr 2007 14:42:44 -0700, tr****@gmail.com wrote:
>On Apr 2, 1:38 pm, trp...@gmail.com wrote:
>I get the same problem on both Windows and Solaris

Is there anything better than adodb, that supports concurrent
transactions. I am still getting the following if I call the same
query at the same time:

Warning: ocilogon() [function.ocilogon]: OCISessionBegin: ORA-03127:
no new operations allowed until the active operation ends
ADOdb is just a wrapper for the various database extensions, in this case the
oci8 extension to access Oracle; it won't be responsible for the error, which
is coming from the database extension level.

--
Andy Hassall :: an**@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool
Apr 3 '07 #6
I am using php version 5.05 and Oracle instantclient_10_2 and adodb
4.96. I was previously using php 4.3.9 and the ora functions, which
worked fine with the same queries, however with php 5+ I cannot use
the ora fxns and insead must use the oci fxns which is where I run
into this problem that I cannot run the same long query at the same
time. I did some more reading about blocking vs. non-blocking
queries... Is it possible to switch between the 2 using php/oci? Or
any other ideas??

Apr 6 '07 #7
Ok, so I upgraded php from 5.0.5 to 5.2.1 and the problem went away,
but it is not so easy for me to upgrade my other Unix envoronment as
anything after php 5.0.5 requires me to upgrade mysql as well. So what
is it about 5.0.5 that is causing this error, and how do I fix it
without upgrading.
Apr 13 '07 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: KLomax | last post by:
I have a VB6 com object that uses ADO 2.1 for data access. I have referenced this object in a aspx application. It works fine on my local development machine. On our staging server, it errors when...
0
by: elcc1958 | last post by:
I need to support a VB6 application that will be receiving disconnected ADODB.Recordset from out DotNet solution. Our dotnet solution deals with System.Data.DataTable. I need to populate a...
0
by: Channing Jones | last post by:
Hello everyone, I am trying to store data in a binary field of an SQL-Server table using ADODB. So far, I have managed to store a record but not any data in the binary field. I only get...
5
by: Simone | last post by:
Hello I hope you guys can help me. I am very new to ADO... I am creating a ADODB connection in a module and trying to access it from a command button in a form. Function fxEIDAssgn(plngEID As...
0
by: Andre Azevedo | last post by:
Hi all ! I've created a .net serviced component with only one method. This method receive an ADODB.Command object and execute it. The ADODB.Command object is created in the client process. (VB...
0
by: ASP.Confused | last post by:
The old message looked a little stale, so I am re-posting it here. Anybody have any ideas of what I could do?!? The previous responses to this question are below. If you want to look at the...
4
by: Ames111 | last post by:
Hi I have an application that connects to a SQl database on my computer via an ADODB connection: ADODB.Connection Conn = new ADODB.Connection(); Conn.ConnectionString = ("Driver={SQL...
6
by: Wonder | last post by:
We have a VB.NET project with a reference to ADO 2.5 When I open it on my machine, I get the following build error: "The referenced component 'ADODB' has an updated custom wrapper available." ...
7
by: Bryan | last post by:
Hi , I am using ADO (ADODB) with access database. Not sure what I am doing wrong.here. Can anyone please help me? string mdbFile = System.IO.Directory.GetCurrentDirectory() +" \\bTrack.mdb;"...
6
by: Oko | last post by:
I'm currently developing an MS Access Data Project (.adp) in MS Access 2002. One of the reports within the DB uses data that is Dynamic and cannot be stored on the SQL Server. To resolve this, I...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.