mysql database tuning
The significance of tuning: 1. Minimize data redundancy. 2. Try to avoid update, insertion and deletion anomalies in data maintenance. 3. Save data storage space 4. Improve query efficiency The significance of tuning: 1. Minimize data redundancy. 2. Try to avoid update, insertion and deletion anomalies in data maintenance. For example, if an entity in the table exists with another entity, an insertion exception will occur. Or if you update a table
- Reduce data redundancy
- Improve query efficiency
1. Minimize data redundancy.
2. Try to avoid update, insertion and deletion anomalies in data maintenance. For example, if an entity in the table exists with another entity, an insertion exception will occur. Or if updating a single attribute of an entity in a table requires updating multiple rows. Or if you delete an entity in a table, other entities will also be deleted.
3. Save data storage space
4. Improve query efficiency
5. Optimize the MIN() and MAX() functions (find the minimum value of a certain column. If the column has an index, you only need to find the leftmost end of the B+Tree index. Otherwise, you can find the maximum value. See below for the specific principle)
6. Terminate the query early (for example: when using Limit, the query will be terminated immediately after finding a sufficient number of result sets)
7. Optimize sorting (in the old version of MySQL, two transmission sorting will be used, that is, first reading the row pointer and the fields that need to be sorted, sorting them in memory, and then reading the data rows according to the sorting results, while the new version uses It is a single transfer sort, that is, reading all data rows at once and then sorting them according to a given column, which is much more efficient for I/O-intensive applications.
8. Avoid page access errors
9. Increase the stability of the database
10. Optimize user experience (optimize the access speed of smooth pages and enhance good website function experience)
11. Optimize cache (separate hot and cold data, appropriately separate data with low access rate to large memory)
Improve cache hit rate, naming issues)
Optimize insert statements, update statements, and delete statements
Optimize field types (including numeric types, character types, time types, Enum and Set)
14. Optimize database server:
Keeping data in memory as long as possible can reduce the workload of disk read and write activities.
It is more important to keep index information in memory than to keep the contents of data records in memory
All users
Product pricing
Product price = ordering interval quantity 1 * interval specification unit price 1 + ordering interval quantity 2 * interval specification unit price 2.
For example: the call rate is 0.3 yuan/minute for the part that does not exceed 3 minutes, and 0.2 yuan/minute for the part that exceeds 3 minutes; if the user calls for 8 minutes, the fee charged is 3*0.3+5*0.2=1.9 yuan.
Product price = order quantity * unit price of the range to which the quantity belongs.
For example: the call rate is 0.3 yuan/minute for no more than 3 minutes, and 0.2 yuan/minute if it exceeds 3 minutes; if the user calls for 2 minutes, the fee charged is 2*0.3=0.6 yuan; if the user calls for 8 minutes, the fee is charged The cost is 8*0.2=1.6 yuan.
Product price = order quantity * unit price.
The product price is the price displayed on the page.
After-sales service time: 5*12 hours After-sales service content: mysql database tuning, error resolution, etc. Service hotline 1: 17601011361 Service hotline 2: 13601077715 Service hotline (landline): 010-86464733 Service email: zqw@zmera.com
By ordering this product you agree toGoods and Services Agreement》