Search Posts

Author: Edward144

PHP Load Data Infile to MySQL Table Certain Columns

I have a CSV file that I need to insert into a MySQL table. However the CSV file has a different number of columns to the table, and the columns are in a different order. The table has these columns: ID, Product_ID, Order_ID, Shipping_Name, Shipping_Postcode, Tracking_Number And the CSV has: Tracking_Number, Order_ID, Name, Postcode (The Product ID is the name of the file and I can set this as a variable in PHP then update […]