整理几个简单的基本sql语句
选择:select * from table1 where 范围
插入:insert into table1(列名1,列名2) values(value1,value2)
删除:delete from table1 where 范围
更新:update table1 set 列名=value where 范围
查找:select * from table1 where 列名=value
排序:select * from table1 order by 列名1,列名2[desc]
总数:select count as totalcount from table1
求和:select sum(列名) as sumvalue from table1
平均:select avg(列名) as avgvalue from table1
最大:select max(列名) as maxvalue from table1
最小:select min(列名) as minvalue from table1
整理几个简单的基本sql语句
最新推荐文章于 2024-06-04 09:54:09 发布