Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Importing a Excel Spreadsheet with DTS

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-10-08 : 09:51:10
John Niemiec writes "This following problem has occured in both SQL 7.0 and now with our upgrade to SQL 2000.

I have a DTS setup to pull data from several Excel 97 spreadsheets that are in the same format. It works, but for simply two records out of all of them it does not pull in a field value from the spreadhsheet and the field ends up being Null. These two records were the last two records of the
spreadsheet which contained about 20 data records.

When I move these two records to the top of the spreasheet to rows 2 and 3(as the row 1 contains column headings) DTS then pulls it in correctly.

For all other records in this spreadsheet, the field in question does not have a value, only for these two of the records does it have a value. The field is a text formatting field on the spreadsheet going to a char(4) table field in the Active X transformation in the DTS.

Anoyone know what would be wrong here? The other speadsheets formatted the same have no problem with the records who have the field value and there not at the top of the spreasheet and seem
to pull in fine. I tried also to look for a preceeding single quote before the field to see if that is causing an issue but a single quote) is not?

Any help would be appreciated."

M.E.
Aged Yak Warrior

539 Posts

Posted - 2002-10-08 : 12:34:21
Actually, we are experiencing a simular problem here. It is able to pick up all values like 1 or 2 but a value of 0001 or 0031 or N results in a null.

If we find a solution I'll let you know... If you find one, pass it on

-----------------------
SQL isn't just a hobby, It's an addiction
Go to Top of Page

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2002-10-08 : 21:24:10
Hi

I've seen this problem. It is the fault of the Excel driver. It only checks the first few rows to determine column sizes and types.

Some info and a workaround here :
http://www.sqlserver.co.nz/content/content.asp?article=98

Hope that helps

Damian
Go to Top of Page
   

- Advertisement -