Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Too many cursors opened on using sys_ref cursor as out parameter in a procedure

Posted on 2007-03-26
4
565 Views
Last Modified: 2013-12-19
All Configurable parameters for the application are stored in a table, various modules of the application read these parameter values through one single interface.

The interface module runs in a separate background thread, which reads the  values of table periodically ( every 3 min) through a Stored Procedure, The stored Procedure uses a ref cursor to return data back to the application.

It was noticed that insetad of using the cusror cache, a new cursor is opened everytime a refresh happens, and these cursors stay open for long time. The Stored proceure itself uses simple select statement without any where clauses to read values from table.(select a,b,c from table abc;)

How do we avoid opening cursor every time the stored proc is executed by the background job. How do we improve the performance.

Regards
Swapna


 
0
Comment
Question by:hiswapna
4 Comments
 
LVL 9

Accepted Solution

by:
konektor earned 125 total points
ID: 18794020
if you use sys_refcursor as output parameter in procedure, it means, that the procedure opens cursor for some select an code which calls the procedure has to close cursor after reading from it
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Note: this article covers simple compression. Oracle introduced in version 11g release 2 a new feature called Advanced Compression which is not covered here. General principle of Oracle compression Oracle compression is a way of reducing the d…
Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
This video shows setup options and the basic steps and syntax for duplicating (cloning) a database from one instance to another. Examples are given for duplicating to the same machine and to different machines

766 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question