dbTalk Databases Forums  

Import text File Error

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Import text File Error in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Ben Rum
 
Posts: n/a

Default Import text File Error - 05-24-2005 , 12:26 PM






I am getting the following error:

"Too many columns found in the current row; non-whitespace characters were
found after the last defined column's data. "

It seems a few people (going by google/newsgroup searches) have encountered
this, but none of which had a very clear resolution.

I am trying to import file into a SQL table.
- Its a pipe/vertical bar delimited
- The file is approx 48mb,
- contains 117,000 odd rows
- has {cr}{lf} as row delimeter

I am running SQL 2000 Sp3.

Any help would be greatly appreciated.





Reply With Quote
  #2  
Old   
Ben Rum
 
Posts: n/a

Default Re: Import text File Error - 05-24-2005 , 12:30 PM






Quote:
I am running SQL 2000 Sp3.
Correction, SP4




Reply With Quote
  #3  
Old   
Darren Green
 
Posts: n/a

Default Re: Import text File Error - 05-24-2005 , 02:41 PM



In message <#VoZEXIYFHA.2572 (AT) TK2MSFTNGP14 (DOT) phx.gbl>, Ben Rum
<bundyrum75 (AT) yahoo (DOT) com> writes
Quote:
I am getting the following error:

"Too many columns found in the current row; non-whitespace characters were
found after the last defined column's data. "

It seems a few people (going by google/newsgroup searches) have encountered
this, but none of which had a very clear resolution.

I am trying to import file into a SQL table.
- Its a pipe/vertical bar delimited
- The file is approx 48mb,
- contains 117,000 odd rows
- has {cr}{lf} as row delimeter

I am running SQL 2000 Sp3.

Any help would be greatly appreciated.

Basically this means the file format is invalid. You probably have
additional data on a line, after DTS has found all of the expected
number of column delimiters. It expects the next delimiter to be the row
delimiter, but instead it has found another column delimiter. I would
start by carving the file in half, load each to find the bad half. Split
again etc.


--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



Reply With Quote
  #4  
Old   
Ben Rum
 
Posts: n/a

Default Re: Import text File Error - 05-24-2005 , 04:47 PM




"Darren Green" <darren.green (AT) reply-to-newsgroup-sqldts (DOT) com> wrote

Quote:
In message <#VoZEXIYFHA.2572 (AT) TK2MSFTNGP14 (DOT) phx.gbl>, Ben Rum
bundyrum75 (AT) yahoo (DOT) com> writes

[snip]

Basically this means the file format is invalid. You probably have
additional data on a line, after DTS has found all of the expected
number of column delimiters. It expects the next delimiter to be the row
delimiter, but instead it has found another column delimiter. I would
start by carving the file in half, load each to find the bad half. Split
again etc.


I have broken the file up, and it works fine when sent in smaller segments.
There is no "offending" row as such.

I read the comments made on the news group posting (link to newsgroup
posting below) which I seem to be getting the same problem. I'm not sure if
any light can be shed on this?

http://groups-beta.google.com/group/...a4dcda52090884






Reply With Quote
  #5  
Old   
Ben Rum
 
Posts: n/a

Default Re: Import text File Error - 05-24-2005 , 05:30 PM




"Ben Rum" <bundyrum75 (AT) yahoo (DOT) com> wrote

Quote:
"Darren Green" <darren.green (AT) reply-to-newsgroup-sqldts (DOT) com> wrote in
message
news:zLfZYhE2N4kCFw0G (AT) sqldts (DOT) com...
In message <#VoZEXIYFHA.2572 (AT) TK2MSFTNGP14 (DOT) phx.gbl>, Ben Rum
bundyrum75 (AT) yahoo (DOT) com> writes

[snip]

Basically this means the file format is invalid. You probably have
additional data on a line, after DTS has found all of the expected
number of column delimiters. It expects the next delimiter to be the row
delimiter, but instead it has found another column delimiter. I would
start by carving the file in half, load each to find the bad half. Split
again etc.


Hi, the large file size (48mb) had me in cutting and pasting confusion.. It
was indeed an extra delimeter in the line..

Thanks for your help




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.