I have a website where one of the functions is importing excel sheets to a SQL database. Right now I am loading the data into a data table and then assigning a variable to a column index. That is working just fine, but if the excel sheet is in a different format then it wont import to the database.
Does anyone know of another way to import a specific column(s) into a SQL database other than using the column index? I have also used the column name, but what if the column name changes?