`

测试脚本mysql_插入100万行数据

阅读更多
CREATE DEFINER=`root`@`localhost` PROCEDURE `APro`()
begin 
     declare num int; 
        set num=1; 
          la:loop 
             if(num<=1000000) then 

  begin 
      insert into tableB (id,name) values (num,'xiaoyi'); 
         set num=num+1; 
  end; 

            else 

         leave la;

             end if; 

               end loop; 
end
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics