Hi,
I have an PHP ode snippet in an dashboard witch counts rows with an select, problem is when the result is no rows at all then i dont get 0 diplayed as i would like.
Is there any way around this?
PHP Code:
$rstmp = CustomQuery("SELECT
COUNT(call
.CallID) AS callstoday
FROM call
INNER JOIN queuecall ON call
.CallID = queuecall.CallID
WHERE (queuecall.QueueDN =6610) AND (call
.WorkgroupCall =1) AND (DATE(call
.StartTime) = DATE(NOW()))
GROUP BY call
.WorkgroupCall
ORDER BY DATE(call
.StartTime) DESC
");
if ($datatmp = db_fetch_array($rstmp))
echo $datatmp["callstoday)"];