From: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com> |
---|---|
To: | David G Johnston <david(dot)g(dot)johnston(at)gmail(dot)com> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Trailing comma support in SELECT statements |
Date: | 2014-10-17 04:42:19 |
Message-ID: | CAFj8pRBFQcAM8zVhG69uSeAj8e-CB3wzTCuBfAsXj0dRrzSXAA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
2014-10-17 6:34 GMT+02:00 David G Johnston <david(dot)g(dot)johnston(at)gmail(dot)com>:
> Jim Nasby-5 wrote
> > On 10/3/14, 4:02 PM, David G Johnston wrote:
> >> Should we also allow:
> >>
> >> SELECT
> >> , col1
> >> , col2
> >> , col3
> >> FROM ...
> >>
> >> ?
> > I would say yes, if we're going to do this. I don't see it being any
> worse
> > than trailing commas.
> >
> > If we are going to do this, we need to do it EVERYWHERE.
> >
> > FWIW, the way I normally "work around" this problem is:
> >
> > SELECT
> > blah
> > , foo
> > , bar
> > , baz
> >
> > In my experience, it's quite uncommon to mess with the first item in the
> > list, which mostly eliminates the issue. A missing leading comma is also
> > MUCH easier to spot than a missing trailing comma.
>
do you know, so this feature is a proprietary and it is not based on
ANSI/SQL? Any user, that use this feature and will to port to other
database will hate it.
Regards
Pavel
> >
> >
> > --
> > Sent via pgsql-hackers mailing list (
>
> > pgsql-hackers@
>
> > )
> > To make changes to your subscription:
> > http://www.postgresql.org/mailpref/pgsql-hackers
>
>
> Jim Nasby-5 wrote
> > On 10/3/14, 4:02 PM, David G Johnston wrote:
> >> Should we also allow:
> >>
> >> SELECT
> >> , col1
> >> , col2
> >> , col3
> >> FROM ...
> >>
> >> ?
> > I would say yes, if we're going to do this. I don't see it being any
> worse
> > than trailing commas.
> >
> > If we are going to do this, we need to do it EVERYWHERE.
> >
> > FWIW, the way I normally "work around" this problem is:
> >
> > SELECT
> > blah
> > , foo
> > , bar
> > , baz
> >
> > In my experience, it's quite uncommon to mess with the first item in the
> > list, which mostly eliminates the issue. A missing leading comma is also
> > MUCH easier to spot than a missing trailing comma.
>
> We might as well allow a final trailing (or initial leading) comma on a
> values list at the same time:
>
> VALUES
> (...),
> (...),
> (...),
> ;
>
>
> David J.
>
>
>
>
> --
> View this message in context:
> http://postgresql.1045698.n5.nabble.com/Trailing-comma-support-in-SELECT-statements-tp5821613p5823365.html
> Sent from the PostgreSQL - hackers mailing list archive at Nabble.com.
>
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
>
From | Date | Subject | |
---|---|---|---|
Next Message | David G Johnston | 2014-10-17 04:46:44 | Re: Superuser connect during smart shutdown |
Previous Message | David G Johnston | 2014-10-17 04:34:59 | Re: Trailing comma support in SELECT statements |