摘要: 1、复习 ->select 查询详解 select distinct(去除重复的) \ top … from + 表名 where + 筛选的条件 group by 分组 having order by ->union uninall ->datediff(second,startdate,endd 阅读全文
posted @ 2020-01-08 22:06 Luohanhui 阅读(173) 评论(0) 推荐(0)
摘要: --聚合函数Use AdventureWorkSlT2008Go Avg() :select avg(score1) as 成绩1,avg(score2) as 成绩2 from 表名 SUM() :select sum(score1) as 成绩1,sum(score2) as 成绩2 from 阅读全文
posted @ 2020-01-08 16:38 Luohanhui 阅读(149) 评论(0) 推荐(0)