dbTalk Databases Forums  

Importing from a delimited text file...

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


Discuss Importing from a delimited text file... in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
William Gordon
 
Posts: n/a

Default Importing from a delimited text file... - 12-13-2005 , 02:40 PM






Hi everyone,

I have a text file that is updated daily (sometimes several times). I need
to read data from this file into two different tables in a SQL database. The
actual import doesn't seem to be tricky with DTS.

The file contains information of this nature:

ClientName, ClientNumber, MatterName, MatterNumber

The problems are as follows:

1. A single Client Name may be associated with multiple Client Matters. I
have a Clients table and a Matters table in my DB. I can copy data into the
repective tables but I don't know how to use DTS to set up the relationship
between the two. In other words, the Matters table uses a ClientRceordId
field to reference the appropriate client for each matter. How can I use DTS
to set up this relationship? (or can I?)

2. I'll be pulling this information every 2 hours. The tables (Clients and
Matters) both have an automatically generated record ID. I'd like to be able
to zap the contents of the table and have the imported data start at the
first row of the table (in other words, at record 0). Can I overwrite the
data like this or will each import just append onto the previous data?

Thanks!!
William Gordon




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.