Hello --
I have two tables:
projectList
client
and currently, there is a string value (a last name) in projectList for the field, client (which is also the name of the other table) --
The client table has a clientID that corresponds to the projectList.client -- that field in the client table is called lName
So here's the breakdown:
client projectList
lName client
clientID
See where I'm going with this? I would like to do a global replace on the projectList table to replace those string values with the clientID that corresponds to it in the client table...
here's what I have that doesn't work --
UPDATE projectList
SET client=(SELECT clientID FROM client WHERE client.lName = projectList.client)
I'm using SQL Server 7.0 -- and would greatly appreciate any guidance anyone could provide --
thx
Paul Prewett
I have two tables:
projectList
client
and currently, there is a string value (a last name) in projectList for the field, client (which is also the name of the other table) --
The client table has a clientID that corresponds to the projectList.client -- that field in the client table is called lName
So here's the breakdown:
client projectList
lName client
clientID
See where I'm going with this? I would like to do a global replace on the projectList table to replace those string values with the clientID that corresponds to it in the client table...
here's what I have that doesn't work --
UPDATE projectList
SET client=(SELECT clientID FROM client WHERE client.lName = projectList.client)
I'm using SQL Server 7.0 -- and would greatly appreciate any guidance anyone could provide --
thx
Paul Prewett