I have insert 14.485 lines on MySQL like this:INSERT INTO `bairros` (`id`,`cidade_id`,`descricao`) VALUES (1,8891,'VILA PELICIARI');INSERT INTO `bairros` (`id`,`cidade_id`,`descricao`) VALUES (2,8891,'VILA MARIANA');...It took around 5 minutes.I had to insert in another table 16.021 lines, same database, so for test I did this:INSERT INTO `bairros` (`id`,`cidade_id`,`descricao`) VALUES (1,8891,'VILA PELICIARI'),(2,8891,'VILA MARIANA');...It took just a few seconds.What is the difference, for the database, between the scripts? And why one is faster than the other?
What's the difference between the insert methods and why one is faster
database;mysql