Avatar of nedlogan
nedlogan
Flag for United Kingdom of Great Britain and Northern Ireland

asked on 

Add Array data to database

Hi,
I have an array of data from an external file which I want to import into my database. So far I can print the ARRAY to the screen.

I have attached the array data in a file (this is how it looks when I print it to the screen) which shows an example with three entries. When I import it into my database I want it to overwrite any duplicates.

I presume I need a foreach loop to read and insert the data?

I'm using PHP / MySQL.

Thanks,
nl
PHPMySQL Server

Avatar of undefined
Last Comment
nedlogan

8/22/2022 - Mon