Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> optimizing in delete-statement

optimizing in delete-statement

From: Ralf Beutler <muelleimer_at_brain4.de>
Date: Fri, 07 Feb 2003 12:55:40 +0100
Message-ID: <b206rt$1883dc$1@ID-19598.news.dfncis.de>


Hi,

following statement works very slow:

DELETE FROM tRoute

	WHERE RouteId IN
	(
	  SELECT ItemId
	  FROM tUserXorganizer
	  WHERE Type = :1 AND FKUserId = :2
	)

;

It performs a full table scan on tRoute. IMHO that's why it has to search all RouteId's and then have a look at tUserXOrganizer to find them there.
Is there a better way for deleting on this table without full table scan? This statement is used in a procedure.

thx

br | rb Received on Fri Feb 07 2003 - 05:55:40 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US