 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Jeff Guest
|
Posted: Wed Dec 03, 2003 1:26 am Post subject: SQLHelpSQL2000 |
|
|
I have 2 tables I am trying to match records up in and update an id
field in table1 from the id field in table2. My only choice is to use
the timestamp and userid. We store the entrydate and userid with each
record and the records in both tables are saved within a few seconds of
each other. I want to loop through table 1, select the records from
table 2 and update a field in table 1 from table two. How can I do this
with SQL on the server? I am using SQL Server 2000.
Update table1 set idfield = select(idfield from table2 where entrydate
like table1.entrydate and userid = table1.userid)
TIA
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|