SQL Server Development Bookmark and Share   
 index > SQL Server Integration Services > Importing Excel 2007
 

Importing Excel 2007

When importing an .xlsx file the number of columns stops at 255. Does anybody know howto get all columns imported?

Triedsaving the file as text and that allows me to import all the columnsbut it wouldbe much easier to do this directly from Excel.

Thanks

Luther88  Thursday, May 15, 2008 3:14 PM

What tools and techniques are you using to import the XSLX file now? As in, what connection manager, data source component and so on.

Does this help at all? http://bi-polar23.blogspot.com/2007/08/but-what-about-excel-2007.html

MatthewRoche  Thursday, May 15, 2008 3:29 PM

I am importing currently with SQL.

I choose Microsoft Office 12 Access Database connector

Change the extended properties to Excel 12.0.

It connects and imports with no issues but it always cuts off the columns at 255. The file I need to import has about 2x as many columns.

Thanks

Luther88  Thursday, May 15, 2008 3:39 PM

Can you try this?

First import it into a .csv text file. Rename the .csv file. Import it to the database from the .csv file.

SQLUSA  Thursday, May 15, 2008 4:12 PM

I have tried to save as CSV. I get all the columns but because a lot of the columns are a mixture of numerical and text values it fails because it is expecting a text value and a number is in the column.

With Excel I have made them all textcolumns.

I have imported the file in two pieces and I will combine the two. Seems the quickest solution for now.

Still would love to import a file directly from Excel 2007 into SQL without going through all this extra work.

Thanks

Luther88  Thursday, May 15, 2008 5:17 PM
Luther88 wrote:

I am importing currently with SQL.

I choose Microsoft Office 12 Access Database connector

Change the extended properties to Excel 12.0.

It connects and imports with no issues but it always cuts off the columns at 255. The file I need to import has about 2x as many columns.

Thanks

So are you using SSIS at all? If not, did you look at the link I posted earlier?

MatthewRoche  Thursday, May 15, 2008 5:30 PM

You can use google to search for other answers

Custom Search

More Threads

• Bulk load xml data from Web Service - SQLXMLBulkLoad vs XML Source
• Look UP Transform
• Could not bulk load because SSIS file mapping object 'Global\DTSQLIMPORT ' could not be opened. Operating system error code 5(Access is denied.)
• Centura/Gupta SQL Windows having problem to set lock wait timeout for SQL Server
• For MSFT, What are the new log messages in SP2?
• Can an SSIS Data Reader call SQLSetConnectAttr API when connecting to an ODBC datasource?
• Problem with SQL Server 2005 > Visual FoxPro Free Tables
• SSIS Fuzzy Grouping >> Exhaustie property
• Configuring Connection Manager for 6.5 database
• where should the .dtsconfig file be deployed on Dev,Prod server