dbTalk Databases Forums  

oracle indexes

comp.databases.oracle.misc comp.databases.oracle.misc


Discuss oracle indexes in the comp.databases.oracle.misc forum.



Reply
 
Thread Tools Display Modes
  #11  
Old   
joel garry
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 03:21 PM






On Jun 4, 9:01*pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? *Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. *But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...” http://www.signonsandiego.com/uniont...s_1n5nude.html


Reply With Quote
  #12  
Old   
joel garry
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 03:21 PM






On Jun 4, 9:01*pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? *Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. *But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...” http://www.signonsandiego.com/uniont...s_1n5nude.html


Reply With Quote
  #13  
Old   
joel garry
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 03:21 PM



On Jun 4, 9:01*pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? *Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. *But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...” http://www.signonsandiego.com/uniont...s_1n5nude.html


Reply With Quote
  #14  
Old   
news.verizon.net
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 10:01 PM




"joel garry" <joel-garry (AT) home (DOT) com> wrote

On Jun 4, 9:01 pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...”
http://www.signonsandiego.com/uniont...s_1n5nude.html

I had forgotten to mention Richard Foote's web site. It is excellent. Lots
of fantastic information there.
Jim




Reply With Quote
  #15  
Old   
news.verizon.net
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 10:01 PM




"joel garry" <joel-garry (AT) home (DOT) com> wrote

On Jun 4, 9:01 pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...”
http://www.signonsandiego.com/uniont...s_1n5nude.html

I had forgotten to mention Richard Foote's web site. It is excellent. Lots
of fantastic information there.
Jim




Reply With Quote
  #16  
Old   
news.verizon.net
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 10:01 PM




"joel garry" <joel-garry (AT) home (DOT) com> wrote

On Jun 4, 9:01 pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...”
http://www.signonsandiego.com/uniont...s_1n5nude.html

I had forgotten to mention Richard Foote's web site. It is excellent. Lots
of fantastic information there.
Jim




Reply With Quote
  #17  
Old   
news.verizon.net
 
Posts: n/a

Default Re: oracle indexes - 06-05-2008 , 10:01 PM




"joel garry" <joel-garry (AT) home (DOT) com> wrote

On Jun 4, 9:01 pm, doug <douglass_da... (AT) earthlink (DOT) net> wrote:
Quote:
Hello,

Say If I have a table with column a, and column b (say they are
integers).

Sometimes I will do a query with a where clause that just references
column a.

Sometimes I will do a query with a where clause that references both
column a and b.

Is there a need to create an index with a, and an index with a, b? Or
will an index with a,b work for both of the above types of queries?

I know in mysql if I have an index (a, b, c), then it is useful for
queries referencing a or a,b or a, b,c. But, I am not as familiar
with how Oracle indexes work.

Thanks.
You should read about indexing in the concepts manual and the
performance tuning manual. You can also search http://tahiti.oracle.com
for the skip scan Jim mentioned, which answers your question.

Once you become comfortable with the basic concepts, you can delve
deeper in many places, especially http://richardfoote.wordpress.com/
(be sure and check out the index internals presentation).

jg
--
@home.com is bogus.
“I just don't understand why kids would do a stupid thing like
that...”
http://www.signonsandiego.com/uniont...s_1n5nude.html

I had forgotten to mention Richard Foote's web site. It is excellent. Lots
of fantastic information there.
Jim




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.