This topic is locked

Dashboard doesn't show listpage record

10/27/2016 5:41:27 AM
PHPRunner General questions
S
snuffi01 author

Have an Dashboard with some charts and also some listpages on it.

I actually want to show values on dashboard witch actually is some simple count and therefore just generates one record.

As example i want to show how many ongoing calls with an BIG numeric value, i want to show logged in users with a big numeric value and so on.

Most values comes from different tables and also different db.

My problem is that if the record to show is 0 (zero) then the dashboard shows nothing, i i look at the listpage itself i see the record displaying 0:


But on the Dashboard it look like this:


My sql:



SELECT

IFNULL(COUNT(DISTINCT(prim_cid)), 0) AS Chat,

events.event_time

FROM events

INNER JOIN event_parties ON events.g_event_id = event_parties.g_event_id

WHERE (events.event_id = 9) AND (DATE(event_time) = CURDATE()) AND event_parties.ani REGEXP '^[[:digit:]].*$'

ORDER BY events.event_time DESC


Result in the Query:


As soon as my result of sql generates a real value as 1 or 2 then dashboard is showing the value as expected.
What am i doing wrong?

Is there any other way of displaying numeric values from sql counts on the Dashboard, can't be an unusual demand?

S
snuffi01 author 11/1/2016



Have an Dashboard with some charts and also some listpages on it.

I actually want to show values on dashboard witch actually is some simple count and therefore just generates one record.

As example i want to show how many ongoing calls with an BIG numeric value, i want to show logged in users with a big numeric value and so on.

Most values comes from different tables and also different db.

My problem is that if the record to show is 0 (zero) then the dashboard shows nothing, i i look at the listpage itself i see the record displaying 0:


But on the Dashboard it look like this:


My sql:



SELECT

IFNULL(COUNT(DISTINCT(prim_cid)), 0) AS Chat,

events.event_time

FROM events

INNER JOIN event_parties ON events.g_event_id = event_parties.g_event_id

WHERE (events.event_id = 9) AND (DATE(event_time) = CURDATE()) AND event_parties.ani REGEXP '^[[:digit:]].*$'

ORDER BY events.event_time DESC


Result in the Query:


As soon as my result of sql generates a real value as 1 or 2 then dashboard is showing the value as expected.
What am i doing wrong?

Is there any other way of displaying numeric values from sql counts on the Dashboard, can't be an unusual demand?


No answer on this?