how to reduce the time for Package to execute [message #307798] |
Thu, 20 March 2008 00:28 |
tannad
Messages: 43 Registered: January 2008 Location: mumbai
|
Member |
|
|
Hi all..
I have one package ,
In this package there are 10 procedure called.
when I call the package it will take so much time
I will give u the procedure in the package
when to delete, millions of rows are deleted same way for update
how I reduce the time of executing the package ..It will take so much time
SELECT a.ROWID BULK COLLECT INTO t_rowids FROM a_acct a,
a_location_gl_definition b
WHERE a.location_id = b.location_id
and a.location_id = p_location_id
FOR UPDATE NOWAIT;
--- delete from a_acct table
IF t_rowids.COUNT > 0 THEN
FORALL i IN t_rowids.FIRST..t_rowids.LAST
DELETE FROM a_acct
WHERE ROWID = t_rowids(i);
COMMIT;
DBMS_OUTPUT.PUT_LINE(t_rowids.count||'Records Are Deleted From The a_acct table..');
END IF;
in this way 4 stmt in each proc
Thanks in advance...
Regards,
Tanad
|
|
|
|
|