Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Count Aggregation

$
0
0

Hi ALL ,

I have a view  that results in the below Output which is based of a very complex length query :

Action LengthMinutes
ADD 37
ADD 37
ADD 25
Delete 1
COPY 1
COPY 3
COPY 1
CUT 2
ADD 24
ADD 37
ADD 62
ADD 50

I wish the output in the below mentioned format :

Here the minutes are grouped as Columns with count of Actions as Value .

Kindly Help

ACTION 0-30min 30-60min 60 + min
ADD 2 4 1
Delete 1 0 0
COPY 3 0 0


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>