leetcode 627. Swap Salary 数据库带判断的更新操作
https://leetcode.com/problems/swap-salary/description/
用 set keyWord = Case depentedWord
when haha then baba
else lala
end
最后需要end
# Write your MySQL query statement below update salary set sex = case sex when 'm' then 'f' else 'm' end;
既然选择了远方,就要风雨兼程~
posted on 2017-11-26 00:28 stupid_one 阅读(278) 评论(0) 编辑 收藏 举报