oracle 常用sql语句
·
SQL分类:
DDL—数据定义语言(CREATE,ALTER,DROP,DECLARE)
DML—数据操纵语言(SELECT,DELETE,UPDATE,INSERT)
DCL—数据控制语言(GRANT,REVOKE,COMMIT,ROLLBACK)
1、DDL
向一个表添加字段
alter table student add sname varchar2(100);
修改已有列名字
alert table
student
修改已有列属性
alter table student modify sname char(20);
修改已有表名字
alter
table student rename
to newstudent;
添加索引
create [unique] index [index_name] on [table_name]( "column_name ")
更多推荐
所有评论(0)