Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Should I use Lookups? How?

Status
Not open for further replies.

rewdee

Programmer
Aug 17, 2001
295
US
I have a DTS package with two connections. We are updating one SQL Server Database into a blank database.

There is one table (call Table1) in the previous database that has a field (call Field1) is just straight text. In the new database, Table1, the Field1 is a lookup field from another table (call Table2)

What I need to do is:
1) Get a Distinct list of items in the first database from Table1.
2) Populate the lookup table, Table2, with the list in the blank db.
3) Insert the records from Table1 from the first database into Table1 in the blank database except with Field1 use the lookup value.

I can do the first two steps but how do I populate the Table1 with the lookup value rather than the text. Would I use Lookups? How?

Thanks,
Rewdee
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top