Home » SQL & PL/SQL » SQL & PL/SQL » How to view if a table indexs are clustered or non clustered? (11g, 11.2.0.3, Windows 7)
How to view if a table indexs are clustered or non clustered? [message #614077] Thu, 15 May 2014 18:38 Go to next message
JP10
Messages: 29
Registered: May 2014
Location:
Junior Member
I've tried using all_indexes, but nothing stands out if the indexs are clustered or not? I want to know if indexs on table are clustered or not. Appreciate the help.
Re: How to view if a table indexs are clustered or non clustered? [message #614078 is a reply to message #614077] Thu, 15 May 2014 18:56 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
Please read and follow the forum guidelines, to enable us to help you:

http://www.orafaq.com/forum/t/88153/0/ and please read http://www.orafaq.com/forum/t/174502/102589/

SQL> select cluster_type, count(*) from dba_clusters group by cluster_type;

CLUST   COUNT(*)
----- ----------
INDEX         10

Re: How to view if a table indexs are clustered or non clustered? [message #614087 is a reply to message #614077] Fri, 16 May 2014 01:08 Go to previous messageGo to next message
Michel Cadot
Messages: 68643
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

Clustered index does not exist in Oracle.
A table is in a cluster or not.
An index is a cluster index or not.
But there is no clustered index.
The (about) same thing in Oracle is an IOT (Index-Organized Table).

Re: How to view if a table indexs are clustered or non clustered? [message #614094 is a reply to message #614077] Fri, 16 May 2014 02:43 Go to previous messageGo to next message
Lalit Kumar B
Messages: 3174
Registered: May 2013
Location: World Wide on the Web
Senior Member
I echo with Michel. It is wonderfully explained by Tom here. The term "Clustered Index" is applicable in some other DB technologies, but not in Oracle. In Oracle the same is called an Indexed Organized Table.
Re: How to view if a table indexs are clustered or non clustered? [message #614111 is a reply to message #614094] Fri, 16 May 2014 11:20 Go to previous messageGo to next message
JP10
Messages: 29
Registered: May 2014
Location:
Junior Member
Thanks guys appreciate the informative content. Last question so is it true that then a primary key creates a clustered index by default?
Re: How to view if a table indexs are clustered or non clustered? [message #614112 is a reply to message #614111] Fri, 16 May 2014 11:29 Go to previous messageGo to next message
Michel Cadot
Messages: 68643
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

There is NO clustered index.

Re: How to view if a table indexs are clustered or non clustered? [message #614113 is a reply to message #614112] Fri, 16 May 2014 11:33 Go to previous messageGo to next message
JP10
Messages: 29
Registered: May 2014
Location:
Junior Member
Haha ok gotcha. Reading the article somebody said in created a clustered index. I got it now thanks guys.
Re: How to view if a table indexs are clustered or non clustered? [message #614114 is a reply to message #614112] Fri, 16 May 2014 11:41 Go to previous messageGo to next message
Solomon Yakobson
Messages: 3273
Registered: January 2010
Location: Connecticut, USA
Senior Member
Michel Cadot wrote on Fri, 16 May 2014 12:29

There is NO clustered index.


Well, technically it does - IOT.

SY.
Re: How to view if a table indexs are clustered or non clustered? [message #614115 is a reply to message #614114] Fri, 16 May 2014 11:47 Go to previous message
Michel Cadot
Messages: 68643
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

http://www.orafaq.com/forum/mv/msg/192759/614087/#msg_614087

The answer is contextual. Smile

Previous Topic: multiple select with and
Next Topic: plsql statment with this output
Goto Forum:
  


Current Time: Tue Apr 23 04:55:22 CDT 2024