agora inbox for pgsql-committers@postgresql.org  
help / color / mirror / Atom feed
From: Fujii Masao <fujii@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Simplify redundant current_database() subqueries in stats.sql re
Date: Mon, 06 Apr 2026 04:21:44 +0000
Message-ID: <E1w9bT5-003BGW-11@gemulon.postgresql.org> (raw)

Simplify redundant current_database() subqueries in stats.sql regression test

Previously the stats.sql regression test used conditions like
"datname = (SELECT current_database())" to check the current database name.

The subquery is unnecessary, so this commit simplifies these expressions to
"datname = current_database()".

Author: Chao Li <lic@highgo.com>
Reviewed-by: Fujii Masao <masao.fujii@gmail.com>
Discussion: https://postgr.es/m/A1535A8F-65AF-4C3D-ACBE-25891CB5D38B@gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/d78a4f0bf058906c5cfd25c815ccbdf18013b312

Modified Files
--------------
src/test/regress/expected/stats.out | 12 ++++++------
src/test/regress/sql/stats.sql      | 12 ++++++------
2 files changed, 12 insertions(+), 12 deletions(-)



Message-ID: <E1w9bT5-003BGW-11@gemulon.postgresql.org>
Permalink:  ../E1w9bT5-003BGW-11@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1w9bT5-003BGW-11@gemulon.postgresql.org

reply

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-committers@postgresql.org
  Cc: fujii@postgresql.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Simplify redundant current_database() subqueries in stats.sql re
  In-Reply-To: <E1w9bT5-003BGW-11@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox