attendance stats in db