MySQL的create table as 与 like区别
来源:互联网 发布:大数据发展的就业前景 编辑:程序博客网 时间:2024/05/27 00:30
对于mysql的复制相同表结构方法,有create table as 和create table like 两种,区别是什么呢?
create table t2 as select * from t1 where 1=2 ; 或者 limit 0;
as创建出来的t2表(新表)缺少t1表(源表)的索引信息,只有表结构相同,没有索引。
create table t2 like t1 ;
like 创建出来的新表包含源表的完整表结构和索引信息
二者的用途:as用来创建相同表结构并复制源表数据
like用来创建完整表结构和全部索引
oracle支持as,也是只有表结构没有索引;oracle不支持like。
0 0
- MySQL create table as 与 like区别
- MySQL的create table as 与 like区别
- MySQL的create table as 与 like区别
- MySQL的create table as 与 like区别
- MySQL create table as与create table like对比
- Mysql create table tb as select 和create table tb like的区别
- mysql复制表结构create table as和like的区别
- MySQL中表结构复制:create table like 与 create table as
- MySQL中表复制:create table like 与 create table as select
- create table tb as select 和create table tb like的区别
- 阿里推荐大赛中 Mysql 中create table as 与like
- mysql表复制create table like和create table as比较
- postgres create table as select & create table like
- DB2的create table like
- insert table 和create table as 区别
- insert into select 与 create table as的用法和区别
- mysql/oracle中create table as的用法
- CREATE TABLE AS语句与循环游标的使用实例
- 【机器学习】【数字信号处理】矢量量化(Vector Quantization)
- Android 的四大组件Content Provider内容提供者
- Prime Land
- oj之大数相减
- python 将二进制字符串转化为字符串 Convert bytes to a Python string
- MySQL的create table as 与 like区别
- C#控制台基础 创建一个匿名类型,并以默认的形式输出整体和单个成员
- java中length属性,length()方法和size()的方法的区别
- 转义字符前后端编解码
- hightCharts图表+angularJS+实时动态显示数据
- boost::bind III
- Pub/Sub 机制
- RCNN(二)SPP-NET:Spatial Pyramid Pooling in Deep Convolutional Networks for Visual Recognition
- springMVC项目,application.xml springmvc-servlet.xml