Answer the question
In order to leave comments, you need to log in
Do I need to make an index in the database on the column by which ORDER_BY is sorted?
I have the following regularly executed query:
SELECT "f_attributes".* FROM "f_attributes" WHERE "f_attributes"."type" IN ('FHeatType') AND (visible = 't') ORDER BY "f_attributes"."title" ASC
Answer the question
In order to leave comments, you need to log in
Postgres has an EXPLAIN (ANALYZE) query profiler. You can feed the request to it and see the request execution plan. From it it will be clear whether indexes are used. There are situations when Postgres does not use an existing index, or only one of two indexes is used.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question