Walid,

It's unlikely that a database parameter will provide the solution to
your problem.

Trace the DELETE if you can (DBMS_SUPPORT.START_TRACE_IN_SESSION), to
see what's taking so long. Odds are that your DELETE is poorly optimized
SQL that's simply doing more work than it needs to be doing. BUT FIND
OUT BEFORE YOU ASSUME THAT'S WHAT IT IS.

If you find that your DELETE is consuming massive amounts of CPU service
or OS read time, then take the query part of your DELETE out of your
DELETE statement, and work with it until you get a decent execution
plan. For example, if your statement were:

        DELETE FROM table
        WHERE predicate-list

...then focus on optimizing the query

        SELECT rowid FROM table
        WHERE predicate-list

At this point, it's a standard SQL optimization exercise. The tools at
your disposal include, but are not restricted to:

- Can you use TRUNCATE to produce a functionally correct end-state?
- Are the statistics on your table reasonable?
- Does your SQL use all the join conditions that are necessary to allow
the Oracle Query Optimizer to do its job of finding the best plan?
- Does your table have all the check constraints on it that the Oracle
Query Optimizer needs to do its job of finding the best plan?
- Do the indexes exist that the Oracle Query Optimizer needs to do its
job of finding the best plan?
- Can you eliminate unnecessary indexes without harming other SQL
statements?
- And so on...

As a last resort, you might consider using hints upon the SQL to coax
the optimizer into using the plan you want, but I would advise doing
this only in unusual circumstances. If all your other work is done
properly, then I would submit that it's usually a good idea to eliminate
hints from your SQL.


Cary Millsap
Hotsos Enterprises, Ltd.
http://www.hotsos.com

Upcoming events:
- Performance Diagnosis 101: 10/28 Phoenix, 11/19 Sydney
- SQL Optimization 101: 12/8-12 Dallas
- Hotsos Symposium 2004: 3/7-10 Dallas
- Visit www.hotsos.com for schedule details...


-----Original Message-----
Walid Alkaakati
Sent: Thursday, October 09, 2003 3:29 AM
To: Multiple recipients of list ORACLE-L

Hi  List ,

Can you  help me please ,

What  are the database parameters that i have to increase or modify in
order to increase the speed of my ddl
statments ,i have a  statment  that delete a table with 40000 record but
it
takes about  nine hours to accomplish !!!

Is their   any parameters on the server  that i have to check
??,Increase
rollback segment is not helpfull at all .
Iam running    oracle  9.2.0.1.0  production .

Thanks for  your help.


Bye.

+----------------------------------------------------------------+ This
message and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to  whom they are
addressed.
If you have received this message in  error please delete it and any
files
transmitted with it, after notifying [EMAIL PROTECTED] Any
opinions expressed in this message may be those of the author and not
necessarily those of the Company.  The Company accepts no responsibility
for the accuracy or completeness of any information contained herein.
This
message is not intended to create legal  relations between the Company
and
the recipient. Recipients should please note that messages sent via the
internet may be intercepted and that caution should therefore be
exercised
before despatching to the Company any confidential or sensitive
information.
+----------------------------------------------------------------+



-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Walid Alkaakati
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Cary Millsap
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to