Quantcast
Channel: Answers for "sum and count with group by in a single column"
Viewing all articles
Browse latest Browse all 6

Answer by SirSQL

$
0
0
A little confused here, why not just use SUM instead of COUNT and eliminate your GROUP BY? Or make your existing select a group by SELECT SUM(BRRCompletedApr13) from (select COUNT(AdjustedDateCompleted) as BRRCompletedApr13 from dbo.shp_BRRPipelineRemediation where AdjustedDateCompleted >='04/01/2013' and AdjustedDateCompleted <'05/01/2013' GROUP BY AdjustedDateCompleted )

Viewing all articles
Browse latest Browse all 6

Trending Articles