Re: [PATCH] Feature improvement for CLOSE, FETCH, MOVE tab completion

From: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>
To: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, Shinya11(dot)Kato(at)nttdata(dot)com
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] Feature improvement for CLOSE, FETCH, MOVE tab completion
Date: 2021-01-11 14:00:36
Message-ID: 28d43417-af7f-c3b8-da19-189a50d2d85c@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2021-01-05 10:56, Masahiko Sawada wrote:
> BTW according to the documentation, the options of DECLARE statement
> (BINARY, INSENSITIVE, SCROLL, and NO SCROLL) are order-sensitive.
>
> DECLARE name [ BINARY ] [ INSENSITIVE ] [ [ NO ] SCROLL ]
> CURSOR [ { WITH | WITHOUT } HOLD ] FOR query
>
> But I realized that these options are actually order-insensitive. For
> instance, we can declare a cursor like:
>
> =# declare abc scroll binary cursor for select * from pg_class;
> DECLARE CURSOR
>
> The both parser code and documentation has been unchanged from 2003.
> Is it a documentation bug?

According to the SQL standard, the ordering of the cursor properties is
fixed. Even if the PostgreSQL parser offers more flexibility, I think
we should continue to encourage writing the clauses in the standard order.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2021-01-11 14:02:18 Re: WIP: System Versioned Temporal Table
Previous Message Konstantin Knizhnik 2021-01-11 13:53:51 Re: libpq compression