I'm having some difficulting on 3.23.38, linux x86... When I write
the following query the HAVING clause is only listening to the 'AND
Samples >= 10' and displas all Avg_Xmit regardless if it's less than
or equal to 28800.
If I remove the 'AND Samples >= 10' I get the correct results, but of
course samples are permitted if less than 10, which I do not want.
Any ideas?
SELECT
INET_NTOA(NAS_Identifier),
NAS_DS1,
AVG(Ascend_Xmit_Rate) as Avg_Xmit,
AVG(Ascend_Data_Rate) as Avg_Recv,
AVG(Acct_Session_Time) / 60 as ACHT,
COUNT(*) as Samples
FROM
tbl_data_call_detail
WHERE
Acct_Session_Time > 0
GROUP BY
NAS_Identifier,
NAS_DS1
HAVING
Avg_Xmit < 28800
AND Samples >= 10
ORDER BY
Avg_Xmit DESC
Regards,
Cliff
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php