Previous: , Up: Creating Tables and Roles   [Contents][Index]


4.3.2 Indexes for Query Performance

The location table has an index that is clustered on the time column to improve the query performance of date range queries. If the table becomes large and performance degrades, run the psql cluster command from time-to-time to re-cluster it. Note an exclusive lock is placed on the table for the duration of the cluster command execution.

See http://dba.stackexchange.com/questions/39589/optimizing-queries-on-a-range-of-timestamps-two-columns for more information.