If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
how to populate a fields in table1 only with related records fromtable2
Hi,
HELP!! I have 2 tables. say table1 has just 2 fields. One called 'ReferenceNbr' which is already populated, and the other called 'Directorate' which is empty at the moment. Now I also have a larger table (Table2). Table2 also has the same 2 fields (amongst others) and has say 5000 records in it. The common relationship between the 2 tables is the 'ReferenceNbr' field. I am trying to populate Table1.Directorate from Table2 where their ReferenceNbr's match, but I keep ending up with hundreds of duplicate fields in Table1. I hope this makes sence. Can someone please tell me where I'm going wrong? Many Thanks Submitted via EggHeadCafe - Software Developer Portal of Choice SQL Server Query Analyzer Runs Fast - Stored Procedure Runs Slow http://www.eggheadcafe.com/tutorials...-analyzer.aspx |
Thread Tools | |
Display Modes | |
|
|