Re: [Minor] Possible missing syntax

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Matemática A3K <matematica(dot)a3k(at)gmail(dot)com>
Cc: "pgsql-docs(at)lists(dot)postgresql(dot)org" <pgsql-docs(at)lists(dot)postgresql(dot)org>
Subject: Re: [Minor] Possible missing syntax
Date: 2026-10-15 16:37:09
Message-ID: CAKFQuwYoj5=j5yWkhDVgPGA-7Fo3sDJMoESO3S_pnc9L=UsE4w@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-docs

On Thu, Oct 15, 2026 at 9:12 AM Matemática A3K <matematica(dot)a3k(at)gmail(dot)com>
wrote:

> and something like "index_start to index_end" ("[2 to 3, 5 to 6]") seems
> unlikely.
>

The row in question is technically correct.

SELECT jsonb_path_query_array(
'[10,20,30,40,50,60]'::jsonb,
'$[1 to 2, 4 to 5]'
) AS result;

[20, 30, 50, 60]

I'll agree the entire section could stand to use examples, like the ones
preceding it.

I'd probably also do:

[{index | start_index to end_index}}, ...]

Instead of leaving the inner syntax available only in the prose.
Or, taking the first and prior rows as multi-syntax examples:

[index, ...]
[start_index to end_index, ...]

And tweak the description accordingly.

David J.

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message rh 2026-10-16 11:33:30 Fix sequence membership command in PG19 release notes
Previous Message Matemática A3K 2026-10-15 16:12:36 [Minor] Possible missing syntax