RE: Anyway to optimize the optimizer

  • From: "Khedr, Waleed" <Waleed.Khedr@xxxxxxx>
  • To: "jaromir nemec" <jaromir@xxxxxxxxxxxx>, <oracle-l@xxxxxxxxxxxxx>
  • Date: Wed, 2 Mar 2005 21:37:16 -0500

This is what I did (explained in my first message), the problem is
Oracle does not substitute the value of C2 in the expression.
Am I missing something?

Waleed



-----Original Message-----
From: jaromir nemec [mailto:jaromir@xxxxxxxxxxxx]=20
Sent: Wednesday, March 02, 2005 7:40 PM
To: Khedr, Waleed; oracle-l@xxxxxxxxxxxxx
Subject: Re: Anyway to optimize the optimizer


Hi Waleed,



I use in this case an additional predicate on partition key:

partition_key >=3D function(value_of_c2)

to cover the missing half of the pruning.

The function calculates the minimal possible value of the partition_key=20
based on the value of the c2 column (in this case: c2 - 10).

This solution is not very user friendly, but at least encapsulates the=20
"business logic" (subtract of 10) in the function.



Any more sophisticated solution will be highly appreciated,



Jaromir

----- Original Message -----=20
From: "Khedr, Waleed" <Waleed.Khedr@xxxxxxx>
To: <oracle-l@xxxxxxxxxxxxx>
Sent: Wednesday, March 02, 2005 6:23 PM
Subject: Anyway to optimize the optimizer


I'm trying to achieve partition pruning when accessing a table using a
column other than the partition key.


--
//www.freelists.org/webpage/oracle-l

Other related posts: