Groups | Blog | Home
all groups > sql server dts > november 2007 >

sql server dts : Import TXT with Index FAILS


Aubrey
11/1/2007 5:13:00 AM
How can I import a Flat File, adding an incrementing Row Number? I tried VB
in Access 2002/SQL 2000 and Access 2007/SQL 2005, using Line Input #1, but
they creep (not responding) then stall with less than 8 percent of rows
imported.

With DTS and SSIS I can Import a 660 MB, 8.8 million record, .TXT file, BUT
the rows appear to be inserted at random. Adding an Identity Column (with or
without PK) causes the import to fail after the last record with an Error
that an IDx of NULL is not allowed.

Can I trap that Error, or otherwise make it non-fatal?

(The legacy system was used for ten years after the VAR disappeared! Tsk!
Tsk! Client can only Kermit into console to print predefined reports.)

This is the SQL CREATE listing:
CREATE TABLE [dbo].[misys] (
[IDx] [numeric](18, 0) IDENTITY (1, 1) NOT NULL ,
[Field1] [nvarchar] (200) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
) ON [PRIMARY]
GO


--
petery NO[at]SPAM online.microsoft.com (
11/2/2007 3:32:16 AM
Hello Aubrey,

I understand that you cannot import TXT file to a SQL table properly. It
always fails at last row with error that an IDx of NULL is not allowed.

I tried on my side to do a similar task without any failure. To isolate the
issue, I'd like to know if you have configure MaximumErrorCount to a bigger
value and set FailpackageOnfailure

If the issue persists, please configure in IIS dataflow panel:

OLEDB Destination --> Edit --> Error Output --> Error to “Redirect Row” and
create a flat file destination to catch the error rows.

Or you could configure OLEDB Destination --> Edit --> Error Output -->
Error to “Ignore Errors”.

If the issue persits, please provide me a sample text file you'd transfer.
Please remove Online from my displayed email address. I will try to
reproduce the issue on my side. Thank you.

Best Regards,

Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications
<http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx>.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
<http://msdn.microsoft.com/subscriptions/support/default.aspx>.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
AddThis Social Bookmark Button