Re: Proposal: %T Prompt parameter for psql for current time (like Oracle has) - Mailing list pgsql-hackers

From Maciek Sakrejda
Subject Re: Proposal: %T Prompt parameter for psql for current time (like Oracle has)
Date
Msg-id CAOtHd0B8+FHsNKVGy8Bg39MX31eg2UpTUd1NxexZgVvOs-WUaA@mail.gmail.com
Whole thread Raw
In response to Re: Proposal: %T Prompt parameter for psql for current time (like Oracle has)  (Nikolay Samokhvalov <samokhvalov@gmail.com>)
Responses Re: Proposal: %T Prompt parameter for psql for current time (like Oracle has)
Re: Proposal: %T Prompt parameter for psql for current time (like Oracle has)
Proposal: :SQL_EXEC_TIME (like :ROW_COUNT) Variable (psql)
List pgsql-hackers
On Thu, Feb 23, 2023, 09:55 Nikolay Samokhvalov <samokhvalov@gmail.com> wrote:
On Thu, Feb 23, 2023 at 9:05 AM Maciek Sakrejda <m.sakrejda@gmail.com> wrote:
I think Heikki's solution is probably more practical since (1) ..

Note that these ideas target two *different* problems:
- what was the duration of the last query
- when was the last query executed

So, having both solved would be ideal.

Fair point, but since the duration solution needs to capture two timestamps anyway, it could print start time as well as duration.

The prompt timestamp could still be handy for more intricate session forensics, but I don't know if that's a common-enough use case.

Thanks,
Maciek

pgsql-hackers by date:

Previous
From: Nazir Bilal Yavuz
Date:
Subject: Re: meson: Optionally disable installation of test modules
Next
From: Sandro Santilli
Date:
Subject: Re: Ability to reference other extensions by schema in extension scripts