Insert 1 milion record |
(09-29-2017, 01:31 PM)omid_student Wrote:(09-29-2017, 01:25 PM)ciadvantage Wrote: Well if ID is primary key then it should be auto-incremented as you set it, so it is taken care off already. Your example is like you can do from code level but it is not recommended. I found it is easier just use this https://dev.mysql.com/doc/refman/5.7/en/load-data.html ie. using command from mysql > LOAD DATA INFILE 'users.txt' INTO TABLE yourdb.users; /* Assume you have db name as yourdb and table users, your users.txt should be comma seperated */ Try a simple test file with few names to see how it goes then you can go from there. |
Messages In This Thread |
Insert 1 milion record - by omid_student - 09-29-2017, 01:15 PM
RE: Insert 1 milion record - by ciadvantage - 09-29-2017, 01:25 PM
RE: Insert 1 milion record - by omid_student - 09-29-2017, 01:31 PM
RE: Insert 1 milion record - by ciadvantage - 09-29-2017, 02:17 PM
RE: Insert 1 milion record - by omid_student - 09-30-2017, 11:17 AM
RE: Insert 1 milion record - by omid_student - 11-07-2017, 08:42 AM
RE: Insert 1 milion record - by Narf - 11-07-2017, 08:54 AM
RE: Insert 1 milion record - by omid_student - 11-07-2017, 11:53 AM
RE: Insert 1 milion record - by fenzy - 11-12-2017, 04:07 AM
RE: Insert 1 milion record - by ciadvantage - 09-30-2017, 02:20 PM
RE: Insert 1 milion record - by omid_student - 10-01-2017, 02:16 AM
RE: Insert 1 milion record - by agus - 11-12-2017, 02:11 AM
RE: Insert 1 milion record - by kilishan - 11-12-2017, 09:49 PM
|