從乙個遠端資料庫的表copy到本地表

2021-07-30 09:03:35 字數 365 閱讀 5430

從乙個遠端資料庫的表copy到本地表

進入sql*plus

sql> copy from username/userpwd@tnsnames例項名 -

> to zqb/zqb@orcl create test01 -

> using select * from 要拷貝的表名;

當在一同乙個伺服器上將乙個表的資料拷貝到另乙個表時,使用create table as select 方法的拷貝速度通常比copy要快

,因為使用copy命令在將資料拷貝到表之前要先將資料從伺服器拷貝到客戶機的sql*plus介面,顯然這增加了開銷,所以相比從

伺服器直接拷貝到相同伺服器copy命令要花費更長的處理時間。

從乙個遠端資料庫的表copy到本地表

從乙個遠端資料庫的表copy到本地表 進入sql plus sql copy from username userpwd tnsnames例項名 to zqb zqb orcl create test01 using select from 要拷貝的表名 當在一同乙個伺服器上將乙個表的資料拷貝到另乙...

SQL 從乙個表複製資料到另一表

複製原表所有資料到新錶 select into 目標表 from 原表或者只複製希望的列插入到新錶中 select column name s into 目標表 from 原表複製原表所有資料到新錶 insert into 目標表 select from 原表或者只複製希望的列插入到新錶中 sele...

從乙個表複製到另乙個表

insert into select語句 語句形式為 insert into table2 field1,field2,select value1,value2,from table1 要求目標表table2必須存在,由於目標表table2已經存在,所以我們除了插入源表table1的字段外,還可以插...