Thread: Related To Query Optimization
Hi Team,
-- I am facing an issue where one of the queries is taking time in production.
When I put that query in explain, I found many nested loop conditions were being used, so just for testing, I disabled the enable_nestloop flag for a session, and now the query is running fast.
I also ran an analyze on every table of that query and also indexing is there on required columns.
When I put that query in explain, I found many nested loop conditions were being used, so just for testing, I disabled the enable_nestloop flag for a session, and now the query is running fast.
I also ran an analyze on every table of that query and also indexing is there on required columns.
Tell me where i am wrong and what can be done, as i don't want to disable it because, according to me, it's not a good practise.
--
Have a Good day !!!
Regards
Rohit Sachdeva
Regards
Rohit Sachdeva
Have a Good day !!!
Regards
Rohit Sachdeva
Regards
Rohit Sachdeva
Am 11.05.23 um 16:50 schrieb ROHIT SACHDEVA:
Hi Team,I am facing an issue where one of the queries is taking time in production.
When I put that query in explain, I found many nested loop conditions were being used, so just for testing, I disabled the enable_nestloop flag for a session, and now the query is running fast.
I also ran an analyze on every table of that query and also indexing is there on required columns.Tell me where i am wrong and what can be done, as i don't want to disable it because, according to me, it's not a good practise.--Have a Good day !!!
Regards
Rohit Sachdeva
I think it's totally impossible to tell without knowing more details.
Please post the CREATE TABLE commands, the number of rows in the tables, the SELECT command and the output of EXPLAIN.
Kind Regards,
Holger
--
Holger Jakobs, Bergisch Gladbach, Tel. +49-178-9759012