导入数据时

关闭索引

  1. ALTER TABLE goods2 DISABLE KEYS;

避免一边创建数据一边重建索引
开启索引

ALTER TABLE goods2 ENABLE  KEYS;