Solved

Procedure taking long time to execute

Posted on 2011-09-19
5
759 Views
Last Modified: 2013-12-07
Hello Experts,

I have a package under which I have a procedure with 6 input parameter and one as out parameter .
I have created a PLSQL block and executed with passing all correct values but it is taking very long time to execute but before two days it was executed in seconds with same parameters.

How to check what is causing the issue from database side.
0
Comment
Question by:Swadhin Ray
5 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 125 total points
ID: 36559525
speed is not about correct paramters, but about indexes and statistics.
you have to check the explain plan for the querie(s), and see what is eventually "missing" ...
0
 
LVL 13

Assisted Solution

by:stergium
stergium earned 125 total points
ID: 36559536
hello.
you might be using tables that need analyse .
try using analyse [table] compute on the tables that you use on this procedure.
it should improve your perfomance (due to reindexing)
hope that helps
please feed back
0
 
LVL 2

Assisted Solution

by:mehuje
mehuje earned 125 total points
ID: 36559537
Hi Slobaray,
please share the explain plan. that's the first thing you need to check. some of the possible causes is listed below.
1) may be the index is not working.
2) recent change ( bulk data insertion or deletion) in those tables which are being used in the code and don't have any recent statistic. so need to check the statistics.
3) change in init.ora file or in some parameters.
4) may be some background process was running at time you executed the procedure.
5) may be network issue, there is too many traffic in the network.
so once again, try to get the explain plan. also check the server is busy or not.

Regards,
0
 
LVL 76

Assisted Solution

by:slightwv (䄆 Netminder)
slightwv (䄆 Netminder) earned 125 total points
ID: 36559647
What does the procedure do?  You might be running into an object lock.

There are a lot of scripts out there that show you how to track locks.

I would start in the online docs:
http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/manproc.htm#sthref764
0
 
LVL 16

Author Closing Comment

by:Swadhin Ray
ID: 36571637
Thanks for all your inputs, for which I am sharing points to everyone .
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Cursors in Oracle: A cursor is used to process individual rows returned by database system for a query. In oracle every SQL statement executed by the oracle server has a private area. This area contains information about the SQL statement and the…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video explains at a high level about the four available data types in Oracle and how dates can be manipulated by the user to get data into and out of the database.
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…

919 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now