国产精品白浆熟女,国产偷亚洲偷欧美偷精品,,新免费无码国产在线看,国产激情久久久久影院老熟女

首頁 SQL壓縮/格式化

[SQL格式化] ,[SQL壓縮] [SQL美化] ,本工具針對 SQL語句 做格式化、美化處理。

在使用的過程中,發(fā)現(xiàn)有BUG,功能不完善,用戶體驗提升等意見,請QQ聯(lián)系站長留言交流即可,謝謝你的支持。

更新時間:2023-09-25 10:38:35
進行格式化或者壓縮操作后再保存哦

工具簡介

1、創(chuàng)建數(shù)據(jù)庫 CREATE DATABASE database-name

2、刪除數(shù)據(jù)庫 drop database dbname

3、備份sql server --- 創(chuàng)建 備份數(shù)據(jù)的 device USE master EXEC sp_addumpdevice 'disk', 'testBack', 'c:\mssql7backup\MyNwind_1.dat' --- 開始 備份 BACKUP DATABASE pubs TO testBack

4、創(chuàng)建新表 create table tabname(col1 type1 [not null] [primary key],col2 type2 [not null],..) 根據(jù)已有的表創(chuàng)建新表: A:create table tab_new like tab_old (使用舊表創(chuàng)建新表) B:create table tab_new as select col1,col2… from tab_old definition only

5、刪除新表 drop table tabname

6、增加一個列 Alter table tabname add column col type 注:列增加后將不能刪除。DB2中列加上后數(shù)據(jù)類型也不能改變,唯一能改變的是增加varchar類型的長度。

7、添加主鍵: Alter table tabname add primary key(col) 刪除主鍵: Alter table tabname drop primary key(col)

8、創(chuàng)建索引:create [unique] index idxname on tabname(col….) 刪除索引:drop index idxname 注:索引是不可更改的,想更改必須刪除重新建。

9、創(chuàng)建視圖:create view viewname as select statement 刪除視圖:drop view viewname

10、幾個簡單的基本的sql語句 選擇:select * from table1 where 范圍 插入:insert into table1(field1,field2) values(value1,value2) 刪除:delete from table1 where 范圍 更新:update table1 set field1=value1 where 范圍 查找:select * from table1 where field1 like ’%value1%’ ---like的語法很精妙,查資料! 排序:select * from table1 order by field1,field2 [desc] 總數(shù):select count as totalcount from table1 求和:select sum(field1) as sumvalue from table1 平均:select avg(field1) as avgvalue from table1 最大:select max(field1) as maxvalue from table1 最?。簊elect min(field1) as minvalue from table1

支付掃碼

所有贊助/開支都講公開明細,用于網(wǎng)站維護:贊助名單查看

查看我的收藏

正在加載... ...