Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

SYS_REFCURSOR takes more time than direct query execution

1052729Nov 5 2013 — edited Nov 12 2013


I have a stored proc which has 4 inputs and 10 output and all outputs are sys_refcursor type.

Among 10 ouputs, 1 cursor returns 4k+ records and all other cursors has 3 or 4 records and average 5 columns in each cursors. For this, it takes 8 sec to complete the execution. If we directly query, it gives output in .025 sec.

I verified code located the issue with cursor which returns 4k+ only.

The cursor opening from a temporary table (which has 4k+ records ) without any filter. The query which inserted into temporary is direct inserts only and i found nothing to modify there.

Can anyone suggest, how we can bring the results in less than 3 sec? This is really a challenge since the code needs to go live next week.

Any help appreciated.


Thanks

Renjish

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 10 2013
Added on Nov 5 2013
8 comments
2,851 views