What I'm wondering is if there is a more denormalized view of this type of data that would make those of types of queries quicker?
pgsql-general by date:
Соглашаюсь с условиями обработки персональных данных