Re: RFC: Logging plan of the running query - Mailing list pgsql-hackers

From Ashutosh Bapat
Subject Re: RFC: Logging plan of the running query
Date
Msg-id CAExHW5uT471q6D=MHvxHZ3zLhgZXDJiVG3Jhm-ngPkv0pk4uBw@mail.gmail.com
Whole thread Raw
In response to Re: RFC: Logging plan of the running query  (jian he <jian.universality@gmail.com>)
List pgsql-hackers
On Mon, Feb 12, 2024 at 5:31 AM jian he <jian.universality@gmail.com> wrote:
>
> I found a bug:
> src8=# select *, pg_sleep(10)  from tenk1 for update;
> 2024-02-11 15:54:17.944 CST [48602] LOG:  query plan running on
> backend with PID 48602 is:
>         Query Text: select *, pg_sleep(10)  from tenk1 for update;
>         LockRows  (cost=0.00..570.00 rows=10000 width=254)
>           Output: unique1, unique2, two, four, ten, twenty, hundred,
> thousand, twothousand, fivethous, tenthous, odd, even, stringu1,
> stringu2, string4, (pg_sleep('10'::double precision)), ctid
>           ->  Seq Scan on public.tenk1  (cost=0.00..470.00 rows=10000 width=254)
>                 Output: unique1, unique2, two, four, ten, twenty,
> hundred, thousand, twothousand, fivethous, tenthous, odd, even,
> stringu1, stringu2, string4, pg_sleep('10'::double precision), ctid
>
> another session (PID) executes `SELECT pg_log_query_plan(48602);` in
> the meantime.
> pg_log_query_plan returns true successfully, but PID 48602 was stuck.

What do you mean by PID 48602 was stuck?

--
Best Wishes,
Ashutosh Bapat



pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: Improve documentation of upgrade for streaming replication section.
Next
From: Ashutosh Bapat
Date:
Subject: Re: RFC: Logging plan of the running query