1UPDATE dbo.TestStudents
2SET LASTNAME = CASE
3 WHEN LASTNAME = 'AAA' THEN 'BBB'
4 WHEN LASTNAME = 'CCC' THEN 'DDD'
5 WHEN LASTNAME = 'EEE' THEN 'FFF'
6 ELSE LASTNAME
7 END
8WHERE LASTNAME IN ('AAA', 'CCC', 'EEE')
9