Win a copy of Programming with Types this week in the Angular and TypeScript forum
or The Design of Web APIs in the Web Services forum!

Sairav Vatts

Greenhorn
+ Follow
since Jan 09, 2020
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Sairav Vatts

I know the post is 3 years old now , but if someone still in same situation .

Try checking the storage engines of tables on both ends(machines) which you are comparing .

> show table status

Usually InnoDB has slower insertion due to the fact it supports txns and will flush logs to disk on each commit . So even if you don't explicitly mention your query under txn , it will commit query each time it is run .
MyISAM on the other hand does not support TXNs , hence faster insertion and no overhead of logging to disk .

You can either change the default-storage-engine in the my.cnf file or you can surround your loop which has insertions by a txn .

Check out this for more info https://stackoverflow.com/a/9819330/3820753 .