be sorted, or it can be added to a column (like joins or additions). Any non-indexed item in the ORDER BY statement, or a computed expression, will slow down the query. Double-check the order BY statement to find non-indexed items or expressions that degrade performance. The solution to this problem is to rewrite the order BY statement to use the index, or you can establish another index for the column you are using, and you should absolutely avoid u
no hidden danger of even slight performance degradation.2.2 ExampleIn the previous section, if Shmmax and sga,oracle create multiple shared memory segments, we can use IPCS-SA to see the number of shared memory segments.(1) View[Email protected] ~]# cat/etc/sysctl.conf | grep Kernel.shmmaxKernel.shmmax = 20971520[Email protected] ~]# Ipcs-sa------Shared Memory Segments--------Key shmid owner perms bytes na
Tags: tabs Other applications ABS SSE contains increased data process structure understandingThe parameters of the tuning function in the Oracle database system are called initialization parameters, and the database administrator needs to properly adjust these initialization parameters to optimize the Oracle system according to the actual situation.1 introduction
the Set TRACE function in Sqlplus analysis of performance and index usage of statements by toad or PL/SQL developer not satisfied with Oracle default optimizations you can force the use of hint, but it is generally not recommended It is generally not recommended to index a field that stores only or no information for flag. You can use bitmap indexing if necessary * There is a recursive query situation
Oracle Adjusts Oracle's competition
One of the benefits of Oracle is that it manages the free space in each table space. Oracle handles the space management of tables and indexes so that we don't have to understand the internal workings of Oracle's tables and indexes. However, for an experienced Oracle
, please look down. First, ask yourself how big the difference is between "Empty" and "null" (if it's int, that's 0 and null)? If you feel that there is no difference between them, then you should not use NULL. (Do you know?) In Oracle, NULL and Empty strings are the same! Do not assume that NULL does not require space, that it requires additional space, and that your program will be more complex when you compare it. Of course, this is not to say that
performance analysis and tuning.
Background knowledge
Main methods of performance analysis
Monitoring: Monitoring is a common way to view the run-time behavior of an application. There are often multiple views (view) that display CPU usage, memory usage, thread state, and other useful information in real time, so that users can quickly discover the key to the
Special Note:
1, this article is only the face of database application development programmer, not suitable for professional DBA,DBA in the database performance optimization needs to know more knowledge;
2, many of the examples and concepts are based on Oracle database description, for other relational database can also be referenced, but many viewpoints are not suitable for KV database or memory database o
relate to the World Cup scoring players in the club's performance, to the first form of association, first know Ronaldinho's ID number, and then find the corresponding club performance. Table 1, a row of data to the corresponding to the 1 columns of data in table 2, table 2 of the 1 columns of data to the corresponding table 1 of the 1 rows of data, in the two large tables in the million bar, this associat
SQL execution is slow, how fast and accurate optimization.
SQLHC is one of the best tools.
By getting all the SQL execution plans, list the actual performance bottlenecks, listing the number of rows on the table where SQL resides, the data and distribution of each column, the existing index, the actual execution of SQL-time, IO, and the number of rows returned.
Specific use of reference Document 1366133.1 SQL
Label:MySQL is a powerful open source relational database management system (RDBMS). It was posted on 1995 (20 ago). It uses Structured Query Language (SQL), which may be the most popular choice in database content management. The latest MySQL version is 5.6.25, released on May 29, 2015. An interesting fact about MySQL is that its name comes from the daughter "My" of Michael Widenius (the founder of MySQL). Although there are many interesting rumors about MySQL, this article is mainly to show yo
.
The customer provided an AWR report during peak hours. After careful analysis, it was found that it was a high-CPU-consuming SQL statement, which only took 85% of the CPU, this gives us an in-depth understanding of SQL optimization. We have also done some DB optimization before, basically through analysis tables, index creation, parameter adjustment, PATCH, and so on. However, this time, it lasted for a week. After learning for a few days, it has not been solved yet. Finally, I decided to stud
is much higher than that of the composite Index query efficiency, while in 11.2.0.3 version Verify that the ad hoc query efficiency of the common composite index is more efficient than the efficiency of the bitmap index) Create TableT (name_id, gender not NULL, location not NULL, Age_range not NULL, data) as Selectrownum, Decode ( Floor(Dbms_random.value (0,2)),0,'M',1,'F') gender, Ceil (Dbms_random.value (0, -) Location , decode ( Floor(Dbms_random.value (0,4)),0,' Child',1,' Young',2,'Middle
rownumObviously, this writing will result in reading the table first, then sorting, and then taking the first 5 records, the plan is as follows:If we write like this, the semantics are the same, but it saves a lot of reading and sorting costs:Select/*+ Index (T1,IDX1_T1) */* from T1 where rownumThe execution plan for this SQL is as follows:As you can see, the SQL does not follow the hint instructions and sequentially scans the IDX1_T1 index, which is why? Personally, it may be that the
Oracle Online tuning redo number of log groups and group membershipsFirst, adjust the redo log group sizeOperation Reason:Redo log general settings allow the log conversion time to 10-20 minutes, and the conversion too often affects performance. Usually do not exceed 6 times per hour! If AWR (automated Workload Repository automatic load repository) report, log fi
to go. In the development, we have to do some optimization of business logic, to avoid complex logic operations, especially to avoid a very large number of cycles of business logic processing, on the one hand we want to simplify business logic, some business logic to the program to deal with, on the other hand we can use SQL very clever to achieve a lot of logic complex requirements, Avoid having to do a lot of complex logic processing, rather than writing more complex SQL statements under com
add data to the table (delete, update operations, and so on), add the address of the new record to the index, which slows down the new data. Presumably, to be able to read it, it's not exactly right. Knowing the index, we can add the appropriate index above the table to improve the performance of the query statement.You can look at an index as a unique table, SQL query, if the field is indexed field will be indexed to query, then the index of this un
-align:middle; "/>There is a question worth thinking about: developing or testing why not in the front of the application of the PID before and after the implementation of the white space function trim, rather than put on the database side to execute, which not only aggravate the workload of the database server,It is also easy to cause the full table scan of large tables due to improper use of the function to reduce the execution speed of SQL; although, creating a trim-based function index on a
Test environment above Oracle database performance parameter settings1. Close the Recycle BinAlter system set Recyclebin=off2. Modify the size of the redo logThe default size of 11g is 50m if redo file compares small OLTP logs more than the case will cause more redo FileSwitch recommended to modify the default size at DBCA time 500m to 1G better.If you have already created and the table is small, you can ex
value that does not exceed 65536, because the upper limit for each IP packet is 65,536 bytes.The sb_max--tunable parameter sets the upper limit for the number of socket buffers queued for a single socket, which can control the total amount of buffer space used by the buffer (queued for sender or received sockets). This amount should normally be less than wall and approximately 4 times times the maximum value of TCP or UDP send and receive settings.The rfc1323--tunable parameter supports the TCP
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.