1.
SELECT Sale.BaoBeiName, Count(*) AS 銷售量
FROM Sale
GROUP BY Sale.BaoBeiName order by Count(*) desc;
2.
SELECT Sale.BaoBeiName, sum(*) AS 合計 FROM Sale
GROUP BY Sale.BaoBeiName order by sum(*) desc;
15個初學者必看的基礎SQL查詢語句,本文將分享15個初學者
表操作 例 1  
上一篇文章已經為配置鏡像數據庫做好了准備,接下來就要進入真
按照本文操作和體會,會對sql優化有個基本最簡單的了解,其
SQL Server 實現數字輔助表實例代碼,sqlserv
但我覺得這個功能用來設置備份服務器或測試服務器也很有用,