Seems to me this is a lot of work to collect metadata that UC4 is already collecting for you, and can be retrieved with SQL. Here is my SQLServer solution that pulls run counts by day;
select oh_name
, convert(varchar(10),dateadd(hour, datediff(hour, getutcdate(), getdate()), ah_timestamp2),20) as run_date
, count(*) as Count
from oh, ah
where oh_idnr = ah_oh_idnr
and oh_name like '%desired.set.of.object.names%'
and dateadd(hour, datediff(hour, getutcdate(), getdate()), ah_timestamp2) between '2018-11-26 00:00:00.000' and '2018-11-27 00:00:00.000'
group by oh_name, convert(varchar(10),dateadd(hour, datediff(hour, getutcdate(), getdate()), ah_timestamp2),20)
EDIT:
I see AlainMoisy suggested the SQL approach too. Need to give credit for that!