I want know how to get the total users website usage total average time for each day. I'm saving the details in database user coming time closing time with FORMAT - DATETIME
SELECT `acu_name` ,AVG(UNIX_TIMESTAMP(acu_et) - UNIX_TIMESTAMP(acu_at)) AS totalTime
ROM `active_user`
GROUP BY `acu_name`
Result :- user01 - 1396.6667 user02 - 2455.0000
here it's coming each user usage time with UNIX_TIMESTAMP FORMAT i want to get that like example(30min or 1hour 30min) and same time i want to get the total users usage time also using laravel and i attached the table format with details please help me to find how out how to do this functions.