I have an excel file which gives in info to be inserted for couple of tables in Database. There are around 40000 rows in Excel. I want to load them into Database. So looks like Stored procedure does the Job from ASP.NET UI. For Example: if the excel file row contains A,B,C,D,E in Column 1, Column2,Column3,Cloumn4,Column5 respectively, then I need to insert (A,C) in Table 1 and (B,D,E) into Table 2. we can assume that this splitting logic is built into the front End code where User inputs the excel file(ASP.NET UI).
But, reading each excel row and sending into the Stored procedure to insert into DB for 40K records seems waste of time and resources. Is there any way that we can read all the rows and pass in all this data in one call to Stored procedure and insert into database? its been too long that I worked with stored procedures and finding it difficult to remember which is the best way to go.