On Mon, 12 Nov 2001 21:20:44 -0800, "Jack Gao" <wei(at)gaofamily(dot)org>
wrote:
>Update tblUserConfig Set Value = '1' From tblUserConfig As a Join
>tblConfigItem As b On a.ItemID = b.ID And b.Scope = 3 Where a.UserID = 1 And
>b.Name = 'UserClassID';
>
>It always update all records in tblUserConfig table!!!
Jack,
don't include the table you want to update in the FROM clause. Just
try:
Update tblUserConfig
Set Value = '1'
From tblConfigItem As b
Where tblUserConfig.ItemID = b.ID
And b.Scope = 3
And tblUserConfig.UserID = 1
And b.Name = 'UserClassID';
Kind regards
Carl van Tast