root@localhost:francs>show createprocedurepro_insertG * 1. row * Procedure: pro_insert sql_mode: STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION CreateProcedure:CREATE DEFINER=`francs`@`localhost` PROCEDURE `pro_insert`() BEGIN DECLAREiINT; SET i = 0; WHILE i <= 10000DO insert into test_1(id, name ) values(i,CONCAT(ID,'_a')); SET i = i + 1; ENDWHILE; END character_set_client: utf8 collation_connection: utf8_general_ci Database Collation: utf8_general_ci 1 row inset (0.00 sec)
查看系统变量
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
root@localhost:francs>show variables like 'log_%'; +----------------------------------------+------------------------------+ | Variable_name | Value | +----------------------------------------+------------------------------+ | log_bin | OFF | | log_bin_basename || | log_bin_index || | log_bin_trust_function_creators | OFF | | log_bin_use_v1_row_events | OFF | | log_error | /database/mysql/data/db1.err | | log_output | FILE | | log_queries_not_using_indexes | OFF | | log_slave_updates | OFF | | log_slow_admin_statements | OFF | | log_slow_slave_statements | OFF | | log_throttle_queries_not_using_indexes | 0 | | log_warnings | 1 | +----------------------------------------+------------------------------+ 13 rows in set (0.00 sec)