由于数据量过大导致报错:The total number of locks exceeds the lock table size

解决方法:

输入查询:show variables like "%_buffer%";

找到对应的 innodb_buffer_pool_size  默认值是 8388608   8兆

将这个数值设置的大一点,比如1G

1G=1024*1024*1024=1073741824

 set GLOBAL innodb_buffer_pool_size=1073741824;

再次输入查询:show variables like "%_buffer%";