Unanswered: transferring data between mySql databases.
I need to get a php page to grab a chunk of records from a table in one database (on a remote server) then write them into a table on the database on the local server before processing them.
the connections are not a probelm, nor is getting the data from the remote server but i want to find a way to write the data in one hit, rather than parsing through the array as it could contain 100'000 records.
anyone got any ideas. even if the connections and getting the data need to be re-written. thanks
The quickest way (from a processing speed standpoint and using minimal code), would be to have your script use - SELECT ... INTO OUTFILE - to save the remote data into a CSV file on your server, then use - LOAD DATA LOCAL INFILE - to put the data into the database.