Enable Index Advisor
Recommends indexes to improve query performance.
This query is using the following index{(usedIndexes ?? []).length > 1 ? 's' : ''}:
No indexes are involved in this query
Indexes may not necessarily be used if they incur a higher cost when executing the query
This recommendation serves to prevent your queries from slowing down as your application grows, and hence the index may not be used immediately after it's created (e.g If your table is still small at this time).
> )} > )} > )}This depends on the expected size of the result set from the query.
For queries that return a small number or rows, the startup cost is more critical and minimizing startup cost can lead to faster response times, especially in interactive applications.
For queries that return a large number of rows, the total cost becomes more important, and optimizing it will help in efficiently using resources and reducing overall query execution time.