DatabaseBest way to optimize query December 29, 2013March 3, 2021 - by Shaunak Sontakke The best way to optimize a query is to understand how the query planner is understanding your query. You may have created indexes on your table but the query planner may not be using it. Share this: