MYSQL數據庫 聚合函數與子查詢

聚合 爲了快速統計數據,提供了5個聚合函數: count(*) 表示計算總的行數,括號中寫 * 與列名,其結果相同 例: select count(*) from students; select count(*) from students where isdelete=1; max(列) 表示求此列的最大值 例: #求gender=1的id的最大值 select max(id) from st
相關文章
相關標籤/搜索