hardbouw
New Member
- Joined
- Jul 31, 2020
- Messages
- 2
- Reaction score
- 0
I am starting to build my own dashboard for Vicidial. I am designing a custom PHP page which displays all the data for me on an TV, I have been checking the database and pulling some stats comparing them to the web interface and Im not getting the same results, they off by a few seconds with the talk time and pause times:
According to the Vicidial Wiki, I am querying the correct table: http://viciwiki.com/index.php/Vicidial_Database_Structure
With the table vicidial_agent_log and column talk_sec.
I am using an MySQL query to pull the talk time of agents from the vicidial mySQL database, here is the query I am running from MySQL:
As you can see above the results I am getting is 12798 Seconds talk time.
When I run the same query from the Vicidial Web, I get this result: 12748 Seconds.
select user,sum(pause_sec) from vicidial_agent_log where event_time > curdate() && user = 8021;
I am getting similar results with the pause times. I have even gone to subtract the 2 values on both the talk time and pause times and I went to do a broader search and omitted the date, the differences is all very different from the mysql query vs the web interface.
I need help to structure my query to get the correct results on my talk time.
I have multiple other queries and all am getting the correct results, just this talk time that Im not getting the correct results.
According to the Vicidial Wiki, I am querying the correct table: http://viciwiki.com/index.php/Vicidial_Database_Structure
With the table vicidial_agent_log and column talk_sec.
I am using an MySQL query to pull the talk time of agents from the vicidial mySQL database, here is the query I am running from MySQL:
Code:
select user,sum(talk_sec) from vicidial_agent_log where event_time > curdate() && user = 8021 && campaign_id = "debtrc";
+------+---------------+
| user | sum(talk_sec) |
+------+---------------+
| 8021 | 12798 |
+------+---------------+
As you can see above the results I am getting is 12798 Seconds talk time.
When I run the same query from the Vicidial Web, I get this result: 12748 Seconds.
select user,sum(pause_sec) from vicidial_agent_log where event_time > curdate() && user = 8021;
I am getting similar results with the pause times. I have even gone to subtract the 2 values on both the talk time and pause times and I went to do a broader search and omitted the date, the differences is all very different from the mysql query vs the web interface.
I need help to structure my query to get the correct results on my talk time.
I have multiple other queries and all am getting the correct results, just this talk time that Im not getting the correct results.