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

Home -> Community -> Usenet -> c.d.o.server -> partition

partition

From: James <jwilkie1_at_gmail.com>
Date: 20 Feb 2007 13:37:27 -0800
Message-ID: <1172007447.585032.101460@h3g2000cwc.googlegroups.com>


Hi,

I have a view that joins two partitioned (range) tables. They have the same partition key - quarter of the year.

The view looks like this:
create view my_view as(
select a.id, a.name, a.quarter, b.id, b.name, b.quarter from tab1 a, tab2 b
where a.id = b.id(+) and a.quarter = b.quarter(+))

And I am invoking the view like this:
select * from my_view where quarter = 4

Due to the outter join, Oracle always scans all 8 partitions from both tables. What do I have to do to get it to realize that I am only asking for the data of the forth quarter and use the proper partition? Thanks!

James. Received on Tue Feb 20 2007 - 15:37:27 CST

Original text of this message

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