解析mysql与Oracle update的区别
摘要:update:单表的更新不用说了,两者一样,主要说说多表的更新复制代码代码如下:Oracle>Oracle的多表更新要求比较严格,所以有的时...
update :单表的更新不用说了,两者一样,主要说说多表的更新
复制代码 代码如下:
Oracle> Oracle的多表更新要求比较严格,所以有的时候不是很好写,我们可以试试Oracle的游标
update (
select t.charger_id_ new_charger_id_
from t_cus_year_status t
left join t_customer_infos cus on cus.id_ = t.cus_id_
where....
) n set n.new_charger_id_ =6;
复制代码 代码如下:
mysql>
update t_cus_year_status t
left join t_customer_infos cus on cus.id_ = t.cus_id_
set t.charger_id_ =6
where......;
【解析mysql与Oracle update的区别】相关文章:
★ 详解MySQL中DROP,TRUNCATE 和DELETE的区别实现mysql从零开始
★ 深入理解mysql SET NAMES和mysql(i)_set_charset的区别
★ mysql -参数thread_cache_size优化方法 小结
★ Mysql 原生语句中save or update 的写法汇总