请问如下功能在oracle中怎么实现?
请问诸位高手:
在MS SQL Server中类似如下的做法,在oracle中如何实现:
例1:存在table1表
...
select *
into #tmp /*请问临时表在oracle中怎么实现?*/
from table1
...
例2:存在A,B表,
A(no integer, num numeric(10,2)) no is primary key
B(no integer, num numeric(10,2)) no is primary key
两表通过no来进行连接,现在A表中的num是错的,要参照B表来修改A表中的num
update a
set a.num = b.num
from a, b
where a.no = b.no
/*请问,这样的功能在oracle中好象无法实现,现在我们在oracle中使用游标来
实现,请问是否有更好的办法?*/
例3:存在A,B表,
A(no1 integer,no2 integer, ....) (no1, no2) is primary key
B(no1 integer, no2 integer ....) (no1, no2) is primary key
两表通过no来连接,现在A中存在一些多余的数据,B表中的数据是正确的,现在想把
A中多余的记录找出来
select a.no, ...
from a left outer join b on (a.no1 = b.no1 and a.no2 = b.no2)
where b.no1 is null
/*这样的写法在oracle中如何实现*/