pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
gram.y comment issue
4+ messages / 3 participants
[nested] [flat]

* gram.y comment issue
@ 2016-03-09 06:04 张文升 <wensheng.zhang@qunar.com>
  2016-03-09 12:54 ` Re: gram.y comment issue Amit Langote <amitlangote09@gmail.com>
  0 siblings, 1 reply; 4+ messages in thread

From: 张文升 @ 2016-03-09 06:04 UTC (permalink / raw)
  To: pgsql-bugs


hello,

The gram.y  includes the line(line:1965):
/* ALTER TABLE <name> ALTER [COLUMN] <colname> SET ( column_parameter =
value [, ... ] ) */
ALTER opt_column ColId RESET reloptions

The comment has the word "SET", but I think that's should be "RESET".

and

src/include/nodes/parsenodes.h line:141
List      *distinctClause; /* a list of SortGroupClause's */ 
The comment has the word "SortGroupClause", but that's should be
"distinctClause".

I apologize if this is too small of an error to be considered a bug, but I
figured that we want to be the best we can.


        regards,wensheng zhang

-- 
----------------------
张文升 | PostgreSQL DBA 



-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: gram.y comment issue
  2016-03-09 06:04 gram.y comment issue 张文升 <wensheng.zhang@qunar.com>
@ 2016-03-09 12:54 ` Amit Langote <amitlangote09@gmail.com>
  2016-03-09 15:31   ` Re: gram.y comment issue Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 4+ messages in thread

From: Amit Langote @ 2016-03-09 12:54 UTC (permalink / raw)
  To: 张文升 <wensheng.zhang@qunar.com>; +Cc: pgsql-bugs

On Wed, Mar 9, 2016 at 3:04 PM, 张文升 <wensheng.zhang@qunar.com> wrote:
> The gram.y  includes the line(line:1965):
> /* ALTER TABLE <name> ALTER [COLUMN] <colname> SET ( column_parameter =
> value [, ... ] ) */
> ALTER opt_column ColId RESET reloptions
>
> The comment has the word "SET", but I think that's should be "RESET".

This one needs to be fixed.

> src/include/nodes/parsenodes.h line:141
> List      *distinctClause; /* a list of SortGroupClause's */
> The comment has the word "SortGroupClause", but that's should be
> "distinctClause".

This one is fine.  The name distinctClause here is parser's way of
referring to the SQL construct DISTINCT ON (<list-of-items>) in a
SELECT query, where each member of the list is a SortGroupClause item.

Thanks,
Amit


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: gram.y comment issue
  2016-03-09 06:04 gram.y comment issue 张文升 <wensheng.zhang@qunar.com>
  2016-03-09 12:54 ` Re: gram.y comment issue Amit Langote <amitlangote09@gmail.com>
@ 2016-03-09 15:31   ` Tom Lane <tgl@sss.pgh.pa.us>
  2016-03-10 02:41     ` Re: gram.y comment issue 张文升 <wensheng.zhang@qunar.com>
  0 siblings, 1 reply; 4+ messages in thread

From: Tom Lane @ 2016-03-09 15:31 UTC (permalink / raw)
  To: Amit Langote <amitlangote09@gmail.com>; +Cc: 张文升 <wensheng.zhang@qunar.com>; pgsql-bugs

Amit Langote <amitlangote09@gmail.com> writes:
> On Wed, Mar 9, 2016 at 3:04 PM, 张文升 <wensheng.zhang@qunar.com> wrote:
>> The gram.y  includes the line(line:1965):
>> /* ALTER TABLE <name> ALTER [COLUMN] <colname> SET ( column_parameter =
>> value [, ... ] ) */
>> ALTER opt_column ColId RESET reloptions
>> The comment has the word "SET", but I think that's should be "RESET".

> This one needs to be fixed.

Agreed, done.

>> src/include/nodes/parsenodes.h line:141
>> List      *distinctClause; /* a list of SortGroupClause's */
>> The comment has the word "SortGroupClause", but that's should be
>> "distinctClause".

> This one is fine.  The name distinctClause here is parser's way of
> referring to the SQL construct DISTINCT ON (<list-of-items>) in a
> SELECT query, where each member of the list is a SortGroupClause item.

Yes.  It might be surprising if you don't know that ORDER BY, GROUP BY,
and DISTINCT all have a common parsetree representation ... but the
comment is correct as written.

			regards, tom lane


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: gram.y comment issue
  2016-03-09 06:04 gram.y comment issue 张文升 <wensheng.zhang@qunar.com>
  2016-03-09 12:54 ` Re: gram.y comment issue Amit Langote <amitlangote09@gmail.com>
  2016-03-09 15:31   ` Re: gram.y comment issue Tom Lane <tgl@sss.pgh.pa.us>
@ 2016-03-10 02:41     ` 张文升 <wensheng.zhang@qunar.com>
  0 siblings, 0 replies; 4+ messages in thread

From: 张文升 @ 2016-03-10 02:41 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; Amit Langote <amitlangote09@gmail.com>; +Cc: pgsql-bugs

thanks !

On 2016年03月09日 23:31, Tom Lane wrote:
> Amit Langote

-- 
----------------------
张文升 | PostgreSQL DBA 



-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



^ permalink  raw  reply  [nested|flat] 4+ messages in thread


end of thread, other threads:[~2016-03-10 02:41 UTC | newest]

Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2016-03-09 06:04 gram.y comment issue 张文升 <wensheng.zhang@qunar.com>
2016-03-09 12:54 ` Amit Langote <amitlangote09@gmail.com>
2016-03-09 15:31   ` Tom Lane <tgl@sss.pgh.pa.us>
2016-03-10 02:41     ` 张文升 <wensheng.zhang@qunar.com>

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