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 -> Basic INDEX and SELECT questions

Basic INDEX and SELECT questions

From: Steve <steve640_at_aol.com>
Date: 7 Sep 2005 20:36:02 -0700
Message-ID: <1126150562.610036.170450@z14g2000cwz.googlegroups.com>


I have some basic index questions that maybe someone can help with. I am just trying to get a better understanding of how this works (without becoming a DBA). If I have a table with fields A, B, and C and it has lots of records. Field A is mostly the same value, field B has a mix of values and field C is almost unique in every record. Given that, here are my questions:
1) Is an index that is created in the order A, B, and C better than one created in the order C, B, and A?
2) When doing a SELECT, is the WHERE clause better being "A=x AND B=y AND C=z" or "C=z AND B=y AND A=x", or no difference? 3) If I had an index on that table of "A,B" and an index just on field "A", how does the system know which index to use and would having these 2 indexes actually hurt?

Thanks for any insight you can provide. Received on Wed Sep 07 2005 - 22:36:02 CDT

Original text of this message

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