The role of Oracle analyze table __oracle

Source: Internet
Author: User
Let's take a brief note.

Today, helping colleagues guide the data, from the development environment to the test environment, found that a query is slow. See the execution plan, and found that the full table scan (about 300w records in the table), why not use the index, view the index status, everything is normal. Dizzy.
Must be the index of the problem, first analysis of the table to say.
Analyze table Ysgl_compile_reqsub Compute statistics for all indexes;

It's normal.

------------------------------------------------------

A post on the forum:

Oracle performance improvement with Analyze table
Url:http://www.itpub.net/thread-295293-1-1.html


Let's talk about this optimization project.
One of the real facts I've come across:
One SQL statement execution takes 1 hours, and sometimes results are not, but after analyzing the tables involved in SQL, then perform 3 minutes to get it done again.
There really is such an amazing difference.

There is no absolute, sometimes you may find that it slows down
Knowing the CBO and Rbo, you know the difference.

The Annlyze table increases the performance of CBO execution. No, not necessarily.
I just ran into a statement. The analysis is performed for more than 30 minutes, after which the analysis is deleted for only 30 seconds.
In many cases, it's best to judge yourself from the execution plan.


This is another way to understand the Oracle optimizer = = Whether I can start to read page 25th.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.