From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: pg_stat_statements: Add tests for SQL/JSON query patterns
Date: Thu, 22 Oct 2026 08:18:34 +0000
Message-ID: <E1xJo0Q-00000000Ipu-1yxi@gemulon.postgresql.org> (raw)
pg_stat_statements: Add tests for SQL/JSON query patterns
A new test file is added to track how the various SQL/JSON query
patterns fare in PGSS, as allowed by the parser:
- Query functions
- JSON_TABLE
- Constructors and predicates.
- etc.
This will be handy for the evaluation of some follow-up patches that aim
to tweak the query jumbling for a portion of some of these SQL/JSON
queries. Some of them are currently slightly broken, tracking as
parameters what should be a keyword, and we never knew about them.
Until now.
The author has written most of the patch. I have noticed a couple of
gaps and some inconsistencies upon further review, leading to a result
more consistent with the usual approach used by the PGSS tests.
Author: Ilya Staroverov <i.staroverov@ftdata.ru>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/457969A9-5D24-422F-B09E-F388053DE028@localhost.localdomain
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/ae75d12b500f01eb3ce9a46418beb2e9301e3e0b
Modified Files
--------------
contrib/pg_stat_statements/Makefile | 1 +
contrib/pg_stat_statements/expected/sqljson.out | 1369 +++++++++++++++++++++++
contrib/pg_stat_statements/meson.build | 1 +
contrib/pg_stat_statements/sql/sqljson.sql | 391 +++++++
4 files changed, 1762 insertions(+)
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: michael@paquier.xyz
Subject: Re: pgsql: pg_stat_statements: Add tests for SQL/JSON query patterns
In-Reply-To: <E1xJo0Q-00000000Ipu-1yxi@gemulon.postgresql.org>
References: <E1xJo0Q-00000000Ipu-1yxi@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 DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox