From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Chema <chema@interneta.org>
Cc: pgsql-performance@lists.postgresql.org
Subject: Re: Optimizing count(), but Explain estimates wildly off
Date: Fri, 01 Mar 2024 09:57:13 +0100
Message-ID: <822fd29fb50b8a8035fd91efa309754b3a02c439.camel@cybertec.at> (raw)
In-Reply-To: <CALdEsqPEouM2tdgrYp--iLA8n7fJf85w5HtBRRqAAA=xBB_sHw@mail.gmail.com>
References: <CALdEsqPScs2bEBxUZC9NO7-Dq2ZGaTQ58gpW=6eiEfq0BbXEsg@mail.gmail.com>
<4bba24a3f55291fd8a17460ed0b3239e3a022c24.camel@cybertec.at>
<CALdEsqPEouM2tdgrYp--iLA8n7fJf85w5HtBRRqAAA=xBB_sHw@mail.gmail.com>
On Thu, 2024-02-29 at 17:15 -0600, Chema wrote:
> No major changes after doing Analyze, and also Vacuum Analyze.
Indeed.
This caught my attention:
> -> Parallel Seq Scan on pricescope_items (cost=0.00..1027794.01 rows=3277101 width=522) (actual time=0.753..41654.507 rows=2621681 loops=3)
Why does it take over 41 seconds to read a table with less than
3 million rows? Are the rows so large? Is the tabe bloated?
What is the size of the table as measured with pg_relation_size()
and pg_table_size()?
Yours,
Laurenz Albe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: laurenz.albe@cybertec.at, chema@interneta.org, pgsql-performance@lists.postgresql.org
Subject: Re: Optimizing count(), but Explain estimates wildly off
In-Reply-To: <822fd29fb50b8a8035fd91efa309754b3a02c439.camel@cybertec.at>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox