Update Data In Table

Update Data In Table

UPDATE posts
SET title = 'Updated First Post'
WHERE postID = 1;

627. Swap Salary

/* Write your T-SQL query statement below */

UPDATE Salary
SET sex =
    CASE sex 
        WHEN 'm' THEN 'f'
        ELSE 'm'
    END;