Excel read range to insert into a database

I’m having trouble extracting data from excel, putting it into a data table and then inserting it into an existing data table on a SQL server. (There is a blacked-out section due to it containing personal information). I have the “AddHeaders” option enabled but not PreserveFormat or UseFilter. The whole process is I am using is simply [Excel Application Scope(Read Range) --> Insert ] with the output for Read Range activity and input for the Insert activity is “table”. Maybe I need to add something else, I’m not entirely sure.

This is the error that it is giving me along with the local value.

It seems that the header is not properly being added due to it having certain words. I am unfortunately not allowed to change the headers so I was wondering if there was a way to somehow get it to work with these headers.

Another picture for clarity as to what my sequence looks like.

@pyoon You have to make the headers to have the same name as in the Database for the Insert Activity to work, also the types should be the same as far as I know.

But if you cannot change the headers at all then you may need to use Execute Non Query Activity and use the Insert SQL Statement to insert each values into table in the database using For Each Loop one by one.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.