数据库A中的表T1,数据库B中有表T2
T1:
ID Score
01 55
02 48 T2:
ID Score Re
01 55
02 46现在我想用Update更新Re,条件是当ID相同,但Score不同时,在Re中标出'*'.这里的目的就是在ID为02的Re中标出*update B.T2 set Re ='*' where (B.T2.Score != A.T1.Score)错误为:找不到A.T1
请高手指教,急
T1:
ID Score
01 55
02 48 T2:
ID Score Re
01 55
02 46现在我想用Update更新Re,条件是当ID相同,但Score不同时,在Re中标出'*'.这里的目的就是在ID为02的Re中标出*update B.T2 set Re ='*' where (B.T2.Score != A.T1.Score)错误为:找不到A.T1
请高手指教,急
解决方案 »
- oracle数据库进行同步数据
- 新手,IMP的导入问题求助!
- 函数能不能用dbms_output.put_line()输出?
- 物化视图同步问题?
- 痛苦啊,俺的win2k一启动到进度条将要结束就马上出现:Stop:c000026c unkonw hard error!!
- 初学oracle,请指点什么意思?
- 关于Java外部例程(高分求一问题答案)
- windows系统中oralce安装失败,请问如何卸载已经安装的东西?
- 特急的ORACLE数据库恢复问题
- oracle怎么删除存储过程,函数,触发器,的语句
- '13-may-08 12:00:00' 格式怎么转成date型。
- Oracle Directory Manager 连接问题
set Re ='*'
where not exits(select 1 from A.T1 t2 where t1.ID = t2.ID and t1.Score = t2.Score)
(
select (case when t1.score<> t2.score then '*' else '' end) from t1,t2 where t1.id=t2.id(+)
and c.id=t1.id)
where exists(select 1 from t2 d where c.id=d.id)
set re='*'
where not exists(select 1 from t1 where t1.id=t2.id and t1.score<>t2.score)
update t2 set re='*' where exists (select 1 from t1@dblinkname where id=t2.id and score<>t2.score)
update B.T2 t1
set Re ='*'
where exits(select 1 from A.T1 t2 where t1.ID = t2.ID and t1.Score <> t2.Score)
update B.T2 t1
set Re ='*'
where exists(select 1 from A.T1 t2 where t1.ID = t2.ID and t1.Score <> t2.Score)