您好,登錄后才能下訂單哦!
數(shù)據(jù)定義語(yǔ)言DDL
create database db_name;
create table table_name (column_name data_type,...);
create view view_name as select .....;
create index on table_name (column_name,...);
drop database db_name;
drop table table_name;
drop view view_name;
drop index table_name.index_name;(不同sql方言不同,這是sql server的寫(xiě)法)
alter table table_name
add column_name data_type
drop column_name;
change column_name new_column_name data_type,...
modify column_name data_type,...
數(shù)據(jù)操縱語(yǔ)言DML
select column_name from table_name where ...
update table_name set column_name=value where ...
insert into table_name (cloumn_name,...) values (value1,...)
delete from table_name where ...
數(shù)據(jù)控制語(yǔ)言DCL:控制權(quán)限
grant select,updat,insert,delete on table_name to 'user_name'@'host_name';
revoke select,updat,insert,delete on table_name to 'user_name'@'host_name';
事務(wù)控制語(yǔ)言TCL:控制事務(wù)
commit
rollback
免責(zé)聲明:本站發(fā)布的內(nèi)容(圖片、視頻和文字)以原創(chuàng)、轉(zhuǎn)載和分享為主,文章觀(guān)點(diǎn)不代表本網(wǎng)站立場(chǎng),如果涉及侵權(quán)請(qǐng)聯(lián)系站長(zhǎng)郵箱:is@yisu.com進(jìn)行舉報(bào),并提供相關(guān)證據(jù),一經(jīng)查實(shí),將立刻刪除涉嫌侵權(quán)內(nèi)容。