Importing Client Data from Excel to MySQL Database

I am currently working on a functionality that will allow a client to upload an excel file with data of their inventory and the functionality will be able to populate the MySQL database with the data. This is not an easy task because it requires precise knowledge of the inventory, and since the database is designed to use relational methodology to solve complex problems, the complexity of such an application is fourfold. The field from the excel file must be known in advance in order to determine how, where, and which table to use for adding and relating the data. So a standard schema of the excel file must be established which will be the model used by the client to enter their inventory data. The programming involved is time consuming because it involves interpreting data from excel and matching data from the MySQL database and if there is new data you have to add the new data and then take the primary key from the table and relate that data to another piece of information that needs to go to another that has a relationship from the previous table, so a lot of tracking and establishing which data is which and which table to relate to each other.

A lot of intelligent logical algorithms have to be programmed in to achieve the goal.