This is what my csv file looks like:

I have three fields (import site, import goods, import status) to import respective data. So if a user clicks on import site only sites name will get saved and the rest won't, similarly for import goods and import status.

The site's data and status's data are saved in a single table but the goods data is being saved in other table with respect to it's site. How do i save them into multiple tables?