I have executed following query:
select count(*), ref, date(updated_at) from `ad` where date(updated_at) >= \'2021-01-16\' and date(updated_at) <= \'2021-0