I have about 40K records that I need to update into my php/mysql application on a daily basis. What is the recommended best approach?
I did some research on load data in file to load the flat-file in a temp MySQL table and run validation on the whole column instead of doing one by one row at a time. Later use the primary key and insert/update that in the database.
However for the data which has MultiSelect options or multiple valid values? How do i validate those before updating them in the database.
Options are delimited using piped.
So for example a multi select data is Color type Valid Values are RED GREEN BLUE BROWN BLACK WHITE
Raw value example case scenarios are
Case 1 Raw Data that needs to be validated RED|GREEN|YELLOW
How can is validate this data in the temp table so RED & GREEN pass thru validation and YELLOW gets stripped out and goes in error log?
How can is do the above validation in Bulk on a csv/tabdelimited flat-file with 40K plus records ?