I'm just trying to understand how to use max and count for my queries. I have the following code:
SELECT SERVICE, COUNT(*)
FROM SUBSCRIBERS INNER JOIN SERVICE_SUBSCRIBERS ON
SERVICE_SUBSCRIBERS.LINE=SUBSCRIBERS.PORTID
GROUP BY SERVICE;
Which outputs:
3WC|12
CFB|17
CWT|20
DSP|16
MSG|25
But I only want to output the maximum (MSG|25). I would also like to know how to output according to a specific condition (>15). I'm just not sure how to use the functions count and max at the same time.