SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Excel Connection Manager issue will only preview data when XLSX spreadsheet is open


Excel Connection Manager issue will only preview data when XLSX spreadsheet is open

Author
Message
Michael J Bonk
Michael J Bonk
Grasshopper
Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)

Group: General Forum Members
Points: 14 Visits: 15
We receive a spreadsheet via FTP from a vendor and have to load the data into SQL Server. When I create the connection manager pointing to the spreadsheet and try to preview the data, I get the following error: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code 0x80004005. Error at Load the Excel Data to the Staging Table [Read all the Rows]; Opening a rowset for "CustomExtract$" failed. Check that the object exists in the database. If I open the spreadsheet in Excel and then go back and preview the data through the control, I can see the rows of data. We process other xlsx spreadsheets daily in SSIS so I think it has soothing to do with this particular spreadsheet. Cannot seem to get the Connection to read this particular spreadsheet. If anyone has experienced this behavior before, please point me in the right direction.

My plan B solution was to convert the spreadsheet to csv and then use a flat file connection to load the data. If anyone knows how to do this using a SSIS script task, it would be appreciated.

Thanks
subbu1
subbu1
Ten Centuries
Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)Ten Centuries (1K reputation)

Group: General Forum Members
Points: 1049 Visits: 695
pls check below link ....
http://www.codeproject.com/Articles/368530/Dynamic-Excel-file-loading-with-SSIS
Michael J Bonk
Michael J Bonk
Grasshopper
Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)Grasshopper (14 reputation)

Group: General Forum Members
Points: 14 Visits: 15
The link contained some very interesting and valuable code which I am sure that I will use sometime in the future. After a lot of research the problem seems to be that the workbooks that we obtain from a vendor were created using some kind of a database filter. The result is that the SSIS EXCEL connection thinks that there are two worksheets in the workbook. The actual worksheet (say Data) and a second worksheet with the name Data_xlnm#_FilterDatabase. To make a long story short the solution is to use a Script task to save the workbook as a csv file and read it in using the Flat File Connection. I have done that and it is working. Thanks for your help.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search