主键 --查询主键SELECT * from user_cons_columns c where c.table_name = '表名'; --删除主键alter table 表名 drop constraint 主键名; --新增主键alter table 表名 add ...
ORACLE: 查主键名称:select from user constraintswhere table name AAA and constraint type P 查主键对应的列:select from user cons columnswhere table name AAA and constraint name PK AAA PK AAA 是主键名 查索引名称:select from ...
2017-07-03 10:43 0 13429 推荐指数:
主键 --查询主键SELECT * from user_cons_columns c where c.table_name = '表名'; --删除主键alter table 表名 drop constraint 主键名; --新增主键alter table 表名 add ...
此文转自:http://blog.sina.com.cn/s/blog_439f80c4010094n1.html 创建主键: alter table T add primary key (V) T是表名,V是列名 创建索引: create index ...
-- 删除普通索引 drop index 索引名字 --创建普通索引 create index 索引名 on 表名(索引对应的列名); --删除主键索引 alter table 表名 drop constraint 索引名 --创建主键索引 ...
= i.table_name and t.table_name = 要查询的表 2、查找表的主键(包括名称,构成列): ...
转载:http://blog.itpub.net/20893244/viewspace-2132149/ ...
1、创建索引 create index 索引名 on 表名(列名); 2、删除索引 drop index 索引名; 3、创建组合索引 create index 索引名 on 表名(列名1,,列名2); *查看目标表中已添加的索引 ...
1、创建索引 create index 索引名 on 表名(列名); 2、删除索引 drop index 索引名; 3、创建组合索引 create index 索引名 on 表名(列名1,,列名2); *查看 ...
/*<br>* *查看目标表中已添加的索引 * */ --在数据库中查找表名 select * from user_tables where table_name like 'tablename ...