Query taking seq scan on a table

From: Shrikant Bhende <shrikantpostgresql(at)gmail(dot)com>
To: pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: Query taking seq scan on a table
Date: 2020-09-20 13:18:46
Message-ID: CAMTQpJA7eNEXJuLk=Yu5ubo0Wp8xYRwFzzpghRshDYCYPmJHJQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hello all,

I am facing issues with one of the queries running on* Amazon Aurora (PG
VERSION 9.6)* which is taking more than a minute to complete. As per the
initial investigation I assume that one part of the query is taking a
sequential scan on a table("wldbowner.member") which is consuming most of
the execution time. I tried to use index (Btree and GIN ) as well but none
of them were helping to get the query to run faster. Attached is the query
along with the explain analyze of the same, any help on the same would be
appreciated.

NOTE : I have done the vacuum on the table already to get rid of bloat
issues.
Reindex and test with more work mem is also helping.

Thanks and regards

Attachment Content-Type Size
Query_Explain.docx application/vnd.openxmlformats-officedocument.wordprocessingml.document 18.7 KB

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Avinash Kumar 2020-09-20 13:25:25 Re: Query taking seq scan on a table
Previous Message Gavin Fleming 2020-09-19 13:47:59 pgAdmin support: setup.py --dump-servers