Re: factorial function/phase out postfix operators?

From: John Naylor <john(dot)naylor(at)2ndquadrant(dot)com>
To: Mark Dilger <mark(dot)dilger(at)enterprisedb(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, Vik Fearing <vik(at)postgresfriends(dot)org>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: factorial function/phase out postfix operators?
Date: 2020-07-18 08:00:12
Message-ID: CACPNZCuc7oN2c8BtyKBCso5oJQ6AfaVh_=VAgiqDown=EhwB5w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Jul 11, 2020 at 1:14 AM Mark Dilger
<mark(dot)dilger(at)enterprisedb(dot)com> wrote:
>
> > Tom and Álvaro discussed upthread:
> >
> >> Would it make sense (and possible) to have a keyword category that is
> >> not disjoint wrt. the others? Maybe that ends up being easier than
> >> a solution that ends up with six or seven categories.
>
> Version 2, attached, follows this design, increasing the number of keywords that can be used as column aliases without the AS keyword up to 411, with only 39 keywords still requiring an explicit preceding AS.

Hi Mark,

This isn't a full review, but I have a few questions/comments:

By making col-label-ness an orthogonal attribute, do we still need the
category of non_label_keyword? It seems not.

pg_get_keywords() should probably have a column to display ability to
act as a bare col label. Perhaps a boolean? If so, what do you think
of using true/false for the new field in kwlist.h as well?

In the bikeshedding department, it seems "implicit" was chosen because
it was distinct from "bare". I think "bare" as a descriptor should be
kept throughout for readability's sake. Maybe BareColLabel could be
"IDENT or bare_label_keyword" for example. Same for the $status var.

Likewise, it seems the actual removal of postfix operators should be a
separate patch.

--
John Naylor https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dean Rasheed 2020-07-18 08:16:39 Re: Wrong results from in_range() tests with infinite offset
Previous Message Tom Lane 2020-07-18 05:03:21 Re: [PATCH] Remove Extra palloc Of raw_buf For Binary Format In COPY FROM