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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Easy softball query

Status
Not open for further replies.

Mdiaz

Programmer
Jul 8, 2002
32
US
Here is an easy question, hope I don't affend you.

I have a table = tblPersonalRecords

that has a field "SSN"

Have another table ( tmpTable )that I imported that has "EmployeeID" and "SSN"

The tblPersonalRecords has the EmployeeID field added now I need to import the Employee ID's to the tblPersonalRecords table.

I can't seem to figure the Update statement to update the tblPersonalRecords table.
Thanks,
Mike Diaz...
 
UPDATE tblPersonalRecords
Set SSN = t.SSN
from tmpTable t
where t.employeeid = tblpersonalrecords.employeeid

-dave
 
Thanks Dave.

Actually the fiels I want to update to the table is the EmployeeID.

So I'll Just

UPDATE tblPersonalRecords
Set EmployeeID = t.EmployeeID
from tmpTable t
where t.SSN = tblpersonalrecords.SSN

Again, tahnks,

Mike Diaz...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top