mysql中的case when then 的用法

将立立饭饭的性别变更为女 ,烦烦 嗯嗯 问我的性别变更为男

update `table`  set 
sex = (
case 
    when sname in('立立','饭饭') 
    then  ''
    else ''
end
)

原文地址:https://www.cnblogs.com/lelexiong/p/11325529.html