Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Index Hint Wont Work

261552Jun 12 2006 — edited Jun 15 2006
I am having problems forcing oracle to use an index using hints. I know based on my knowledge of the data that the first 2 tables accessed radically narrows down the number of rows selected from the driving tables. One of the filtering criteria being a column that is not indexed. Oracle seems to think that there is not much selectivity in the driving tables and seems to have decided that it should do full table scans on the remaining tables.

If I qualify the driving table with a primary key, then Oracle accepts my hints. I don't see that there is a way for Oracle to know that selection criteria on the first two tables dramatically narrows down the number and the selectivity of the remaining tables is very small. Is there a way to force oracle to use indexes.

I think I had this problem before and I used the rule hint. At the time I also needed to change the oracle sql syntax so that it did not use any new syntax. I don't this is an option this time.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 13 2006
Added on Jun 12 2006
7 comments
678 views