insertintoselect和selectinto的使用和区别介绍
来源:动视网
责编:小采
时间:2020-11-09 07:06:23
insertintoselect和selectinto的使用和区别介绍
insertintoselect和selectinto的使用和区别介绍:insert into ... select ...:可将表1中的全部数据或者部分数据复制到表2中。 eg: 代码如下: insert into t2(id,name,pwd) select id,name,pwd from t1 注:t2必须存在。t1中查询的列名可不与t1列名相同。无 values select...int
导读insertintoselect和selectinto的使用和区别介绍:insert into ... select ...:可将表1中的全部数据或者部分数据复制到表2中。 eg: 代码如下: insert into t2(id,name,pwd) select id,name,pwd from t1 注:t2必须存在。t1中查询的列名可不与t1列名相同。无 values select...int

insert into ... select ...:可将表1中的全部数据或者部分数据复制到表2中。
eg:
代码如下:
insert into t2(id,name,pwd)
select id,name,pwd from t1
注:t2必须存在。t1中查询的列名可不与t1列名相同。无 values
select...into:查询t1中的数据,插入到t2中。
eg:
代码如下:
select * into t2 from t1
注:t2被创建并填充数据。
您可能感兴趣的文章:
数据库插入数据之select into from与insert into select区别详解解析MySQL中INSERT INTO SELECT的使用SELECT INTO 和 INSERT INTO SELECT 两种表复制语句简单介绍INSERT INTO SELECT语句与SELECT INTO FROM语句的一些区别insert select与select into 的用法使用说明mssql insert into 和insert into select性能比较select into 和 insert into select 两种表复制语句insert into tbl() select * from tb2中加入多个条件SELECT INTO 和 INSERT INTO SELECT 两种表复制语句详解(SQL数据库和Oracle数据库的区别)
insertintoselect和selectinto的使用和区别介绍
insertintoselect和selectinto的使用和区别介绍:insert into ... select ...:可将表1中的全部数据或者部分数据复制到表2中。 eg: 代码如下: insert into t2(id,name,pwd) select id,name,pwd from t1 注:t2必须存在。t1中查询的列名可不与t1列名相同。无 values select...int