結(jié)構(gòu)化查詢語(yǔ)言(structured query language)簡(jiǎn)稱sql,結(jié)構(gòu)化查詢語(yǔ)言是一種數(shù)據(jù)庫(kù)查詢和程序設(shè)計(jì)語(yǔ)言,用于存取數(shù)據(jù)以及查詢、更新和管理關(guān)系數(shù)據(jù)庫(kù)系統(tǒng);
sql語(yǔ)句就是對(duì)數(shù)據(jù)庫(kù)進(jìn)行操作的一種語(yǔ)言。(推薦學(xué)習(xí):MySQL視頻教程)
程序功能
創(chuàng)建數(shù)據(jù)庫(kù)
CREATE DATABASE database-name
刪除數(shù)據(jù)庫(kù)
drop database dbname
創(chuàng)建新表
create table tabname(col1 type1 [not null] [primary key],col2 type2 [not null],..)
刪除新表
drop table tabname
常見(jiàn)語(yǔ)句
更新:update table1 set field1=value1 where 范圍
查找:select * from table1 where field1 like ’%value1%’ (所有包含‘value1’這個(gè)模式的字符串)
排序:select * from table1 order by field1,field2 [desc]
求和: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[separator]
更多MySQL相關(guān)技術(shù)文章,請(qǐng)?jiān)L問(wèn)MySQL教程欄目進(jìn)行學(xué)習(xí)!
以上就是sql語(yǔ)句是什么的詳細(xì)內(nèi)容,更多請(qǐng)關(guān)注php中文網(wǎng)其它相關(guān)文章!
每個(gè)人都需要一臺(tái)速度更快、更穩(wěn)定的 PC。隨著時(shí)間的推移,垃圾文件、舊注冊(cè)表數(shù)據(jù)和不必要的后臺(tái)進(jìn)程會(huì)占用資源并降低性能。幸運(yùn)的是,許多工具可以讓 Windows 保持平穩(wěn)運(yùn)行。
微信掃碼
關(guān)注PHP中文網(wǎng)服務(wù)號(hào)
QQ掃碼
加入技術(shù)交流群
Copyright 2014-2025 http://ipnx.cn/ All Rights Reserved | php.cn | 湘ICP備2023035733號(hào)