dbTalk Databases Forums  

Re: Oracle and PHP with Cursors

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss Re: Oracle and PHP with Cursors in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
DA Morgan
 
Posts: n/a

Default Re: Oracle and PHP with Cursors - 11-16-2007 , 06:57 PM






Björn Wächter wrote:
Quote:
Hi all,

we are using Oracle and PHP for a Web application.
We are using ref cursors to return data from oracle
to php.


PROCEDURE GetData(
p_form IN VARCHAR2,
crs_data OUT Usertype.ref_cursor
)
AS
...
BEGIN
....

OPEN crs_data FOR v_sql;

END;



CREATE OR REPLACE PACKAGE usertype AS

TYPE ref_cursor IS REF CURSOR;

END usertype;


We are facing the problem that retrieving the data over
the cursor is quite slow because we see in the trace that
every row is request with one call to oracle. We enabled
prefetching in PHP but as fare as we know this is not
possible for cursors. We need the flexibility of cursors
to be able to return different numbers of columns in each
request.
Any ideas how we can solve this problem?
We read something about scrollable cursors. Is this a way?

Thanks Björn
Oracle version number.
DDL would be helpful.
Information such as the number of rows being returned useful.
Is there a WHERE clause anywhere in sight?
Has the statement been tuned? How? With DBMS_XPLAN?
--
Daniel A. Morgan
Oracle Ace Director & Instructor
University of Washington
damorgan@x.washington.edu (replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.