Re: explain analyze rows=%.0f - Mailing list pgsql-hackers

From Ibrar Ahmed
Subject Re: explain analyze rows=%.0f
Date
Msg-id CALtqXTfosCrM-7B2HxitSMo8CNPGWOZ+nstwPbAiZVxJ3tfjnA@mail.gmail.com
Whole thread Raw
In response to Re: explain analyze rows=%.0f  (Greg Stark <stark@mit.edu>)
List pgsql-hackers


On Thu, Jul 7, 2022 at 10:53 PM Greg Stark <stark@mit.edu> wrote:
> -               ->  Parallel Seq Scan on tenk1 (actual rows=1960 loops=50)
> +               ->  Parallel Seq Scan on tenk1 (actual rows=1960.00

At the not inconsiderable risk of bike-shedding....

I'm wondering if printing something like 0.00 will be somewhat
deceptive when the real value is non-zero but less than 1 row per 200
loops. I wonder if the number of decimal places should be calculated
to produce a minimum of one non-zero digit for non-zero values.

--
greg

+               ->  Parallel Seq Scan on tenk1 (actual rows=1960.00

I have added a new check to remove any ".00" from the output because in
the case of parallel queries we are getting that. Secondly, it is disturbing many test case outputs.

--
Ibrar Ahmed

pgsql-hackers by date:

Previous
From: Ibrar Ahmed
Date:
Subject: Re: explain analyze rows=%.0f
Next
From: Tom Lane
Date:
Subject: Re: automatically generating node support functions