这个update怎么写啊?
create table aa(a number, b number, c number)
create table bb(a number, b number, c number)
aa
a b c
1 0 0
2 0 0
3 0 0
bb
a b c
1 1 1
2 2 2
3 3 3
4 4 4
现在要根据aa中的a字段和bb中的a字段来更新aa的数据,得到
a b c
1 1 1
2 2 2
3 3 3
我想到了这种方法,但是不好,重复了
update aa ta set ta.b = (select b from bb where ta.a = a),ta.c = (select c from bb where ta.a = a)
大家帮忙看看
...全文
相关推荐
Eclipse插件开发打包为Update Site
Eclipse插件开发打包为Update Site 开发完后的插件如何打包。
SFLive-Paris2013-Twig:Symfony live-巴黎2013-如何组织分支机构模板?
Symfony Live-巴黎2013年-树枝 它是什么 ? 写一些幻灯片,与编译 ,看到它与 要求 安装 git submodule update --init 用法 只需运行./build.sh并打开index.html 帮助
板子烧写工具.txt
板子烧写工具.txt 板子烧写工具.txt板子烧写工具.txt 板子烧写工具.txt 板子烧写工具.txt
SQL Server UPDATE语句的用法详解
SQL Server中的数据改动是免不了的,使用UPDATE语句就可以实现我们对数据库数据的更新修改操作,下面就让我们来了解一下UPDATE语句的用法
for_update_和_for_update_nowait_的区别
for_update_和_for_update_nowait_的区别


基础和管理
