摘要:
1、首先使用非聚集索引SET STATISTICS IO ON SET STATISTICS TIME ON SELECT MemberId , MAX(AddDT) AS RecentSucDT ,--最近成功订单日期 COUNT(1) AS SucOrderNum ,--成功订单数 SUM(VExpd) AS SucAmount ,--成功订单金额 DATEDIFF(DD, MIN(AddDT), MAX(AddDT)) AS Tenure ,--活跃天数 DATEDIFF(DD, MAX(AddDT), GETDAT... 阅读全文
posted @ 2013-07-10 14:18 迷糊妖 阅读(516) 评论(0) 推荐(0) 编辑