select into from
SQLSERVER 创建表:
select * into aaa from bbb
Oracle 创建表:
create table aaa as select * from bbb
select into from 用在oracle 是 赋值。如下:
SELECT TRUNC(SYSDATE-1,‘DD‘) INTO ACTIONTIME FROM DUAL;
获取昨天的日期赋值给 actiontime 这个变量。
insert into select
表之间数据的复制,如下:
1
|
insert into
t1(id1,name1) select
3, name2 from
t2
|