oracle中的这个update怎么写? update taba a set deptno=(select deptno from tabb b where a.id=b.id); 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 应该这么写吧 update taba a set deptno=(select deptno from tabb b,tabA a where a.id=b.id); update taba a set deptno=(select deptno from tabb b,tabA a where a.id=b.id); 以上三位人兄都对,但涉及到多记集时,会出错update taba a set deptno=(select deptno from tabb b where a.id=b.id rownum<=1 order by deptno .....); update taba a set deptno=(select deptno from tabb b,tabA a where a.id=b.id);这样写不对呀,有一个致命的问题:taba中如果 id在 tabB中没有,则更新后结果变成null 啦,怎么办哪 应该是update taba a set deptno=(select deptno from tabb b,tabA a where a.id=b.id) where a.id in (select id from tabB b where a.id = b.id); update taba a set deptno=(select deptno from tabb b,tabA a where a.id=b.id(+)); update taba a set deptno=nvl((select deptno from tabb b,tabA a where a.id=b.id(+)),0); 请教oracle过程实现金额转换 请教这种情况下这个update语句怎么写? oracle10.2.0 遇到的问题 oracle 导入数据问题 oracle Wrap 问题求解 配置网罗服务名称出错 安装oracle后修改了机器名称,OracleOraHome92TNSListener服务起不来,不将名称改回去,需要修改哪些文件? 有关删除数据库的问题?谢谢! 请问oracle中怎样更表的字段类型或名字?? 二进制存取方案 oracle在win2000server里的安装问题!!!!THANKS! 最影响Oracle系统性能的初始化参数
taba中如果 id在 tabB中没有,则更新后结果变成null 啦,怎么办哪
update taba a set deptno=(select deptno from tabb b,tabA a where a.id=b.id) where a.id in (select id from tabB b where a.id = b.id);