openactive-archive / conformance-services

Harvests and normalises OpenActive Opportunity feeds to a common representation
MIT License
0 stars 0 forks source link

Database Indexes #105

Closed odscjames closed 3 years ago

odscjames commented 3 years ago

Adding some might help some queries.

odscjames commented 3 years ago

I tried

CREATE INDEX normalised_data_updated_at_data_id_idx ON normalised_data (updated_at, data_id);

first, as I was worried to make sure the web end point didn't have issues. According to EXPLAIN, postgres doesn't care and does a Parallel Seq Scan anyway!

odscjames commented 3 years ago

Database Indexes

michaelwood commented 3 years ago

We added a bunch of useful indexes. See migrations for details.