16. mysql partitioning-SQL optimization 2
1. index classification B-Tree supports HASH. Only memory supports R-Tree myisam and supports Full-text myisam (Full-text index. only the "=" condition in the Memory engine uses the index ======================== === data import optimization =========================== 3. how to improve myisam import efficiency alter table emp disable keys; disable index load data infile 'AA. SQL 'into table emp; import data to emp alter table emp enable keys; enable index 4. how to improve the efficiency of innodb import data can be arranged in the order of primary keys. disable the uniqueness check set unique_checks = 0; load data infile .... set unique_checks = 1; enable the check ================================== Insert optimization ==== ================================= 1. insert into emp values (1, 2, 3), (1, 2 ),..... ==================================== page optimization ======== ================================= 1. use inner join inline 2. the general idea of processing on the application end is to record the id of the last record on the previous page. the next page uses this id as the starting value, but this must ensure that the id is unique.