Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
mike123
Master Smack Fu Yak Hacker
1462 Posts |
Posted - 2002-04-04 : 21:06:33
|
| I have 2 tables. tblInstantMessage and tblUserDetailsI am in the process of normalizing the database, I would like to delete all the userID's in tblInstantMessage that do not appear in the UserID of tblUserDetails.Is there a way to do this?ThanksMIke |
|
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2002-04-04 : 21:08:39
|
| DELETE FROM IMFROM tblInstantMessage IM LEFT JOIN tblUserDetails UON IM.UserID=U.UserIDWHERE U.UserID Is Null |
 |
|
|
|
|
|