单表 单字段多条件更新
2011-05-23 18:21
176 查看
请问 这样多条件更新 如何写?
update ods_dictionary
set module_note='成功变更邮箱设置'
where module_id=12
set module_note='点击邮箱'
where module_id=13
update ods_dictionary
set module_note=decode(module_id,13,'点击邮箱营销链接等行为',14,'基础邮箱其它行为')
where module_id in (14,13)
update ods_dictionary
set module_note='成功变更邮箱设置'
where module_id=12
set module_note='点击邮箱'
where module_id=13
update ods_dictionary
set module_note=decode(module_id,13,'点击邮箱营销链接等行为',14,'基础邮箱其它行为')
where module_id in (14,13)
相关文章推荐
- 根据条件更新字段
- oracle sql通过判断条件更新数据库某个字段的值内容
- mybatis 多字段、多表批量更新,判断条件也批量改变
- SQL根据条件批量update更新字段案例
- 根据条件用一个表的字段,去更新另一个表的字段
- JSONArray 字段数据 按条件 更新
- 将一张表的字段根据条件更新到另一张表的一个字段中去
- thinkphp根据条件取得id值并更新个别字段的值
- sql总结之 被作为where过滤条件的字段 ,其值也是可以被更新的
- oracle数据库批量更新某个字段的值where条件是个集合
- sqlserver中用不重复的条件更新两个表对应字段字段。
- 同一字段根据不同条件更新的sql语句的写法
- 两个表字段之间的批量更新实现的是将a表中的a1 更换成b表中的b2,条件是a1 = b1,并且a1和b1都是唯一的。
- 【数据库】同一字段根据不同条件更新的sql语句的写法
- mysql 同一个字段作为条件更新
- 更新 将B表的数据更新到A表中的某个字段的sql(根据条件)
- sql语句的构造,当where后的条件个数不定,当update set后的更新字段数不定
- update语句根据条件更新某字段的值
- SQL两表匹配,将A表的指定字段所有内容根据条件更新B表指定字段的所有内容
- ElasticSearh更新nested字段(Array数组)。怎么根据查询条件(query)复制一个(index)到新的Index how to update by query a nested fields data for elasticsearch