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)
 Import into multiple linked tabels

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-08-06 : 09:33:55
Gino writes "How to import an excell file into multiple linked tabels.

Record : ProducktNo,ProductDescription, ProductGroup
Tables : Product,ProductDescription, ProductGroup

Requirements : when a ProductGroup doesn't exist it must be created in the ProductGroup table and ProductGroupId must be stored into Product table. If ProductGroup exist ProductGroupId is inserted in ProductTable.
The same principle for productdescription

Regards in advance"

Page47
Master Smack Fu Yak Hacker

2878 Posts

Posted - 2002-08-06 : 10:51:44
If I were you, I would dump directly into a 'staging' table than then write out the appropriate dml to populate your production tables from that.

You will need to insert new values into your description and group tables first, then insert into your product table joining your staging table to your two lookup tables....

Jay White
{0}
Go to Top of Page
   

- Advertisement -