-
If I run ANALYZE TABLE table_name COMPUTE STATISTICS;
am I analyzing indexes also?...how about indexed columns?
or do I need to run following command along with the first one?
ANALYZE TABLE table_name COMPUTE STATISTICS FOR ALL INDEXES
ANALYZE TABLE table_name COMPUTE STATISTICS FOR ALL INDEXED COLUMNS
If I want to have complete analyze on tables, indexes, and etc.... which command should I use?
-
You should analyze the indexes separately.
To analayze all indexes in a given schema, run the following:
exec sys.dbms_utility.analyze_schema ('OWNER','COMPUTE',NULL,NULL,'FOR ALL INDEXES')
-
I thought that analyzing the tables also analyzed the indexes. For all indexes only analyzes the index.
I only analyze my tables so I hope im not suffering a performance hit because of it.
-
Analyze
Hi,
Analyze table TABLE_NAME compute statistics...
This command analyze all tables, all associated Indexes, all partitions of tables as well as all partitioned indexes. So you don't need to run seperate analyze index.
Thanks
-Puneet
-
Originally posted by UNIX DBA
I thought that analyzing the tables also analyzed the indexes. For all indexes only analyzes the index.
You are correct. ANALYZE on table automatically collects the statistics for each of the table's indexes and domain indexes, provided that no for_clauses are used.
Sam
Thanx
Sam
Life is a journey, not a destination!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|