Re: GROUP BY DISTINCT
Georgios <gkokolatos@protonmail.com>
From: Georgios <gkokolatos@protonmail.com>
To: Vik Fearing <vik@postgresfriends.org>
Cc: "pgsql-hackers@lists.postgresql.org" <pgsql-hackers@lists.postgresql.org>,
Erik Rijkers <er@xs4all.nl>
Date: 2021-03-02T19:21:42Z
Lists: pgsql-hackers, pgsql-docs
‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐ On Tuesday, March 2, 2021 5:51 PM, Vik Fearing <vik@postgresfriends.org> wrote: > On 3/2/21 4:06 PM, Georgios Kokolatos wrote: > > > As a minor gripe, I would note the addition of list_int_cmp. > > The block > > > > - /* Sort each groupset individually */ > > > > > > - foreach(cell, result) > > > > > > - list_sort(lfirst(cell), list_int_cmp); > > > > > > > > Can follow suit from the rest of the code, and define a static cmp_list_int_asc(), as > > indeed the same patch does for cmp_list_len_contents_asc. > > This is indeed point of which I will not hold a too strong opinion. > > I did it this way because list_int_cmp is a general purpose function for > int lists that can be reused elsewhere in the future. Whereas > cmp_list_len_contents_asc is very specific to this case so I kept it local. Of course. I got the intention and I have noted my opinion. > > I'm happy to change it around if that's what consensus wants. As before, I will not hold a too strong opinion. > > > Overall :+1: from me. > > Thanks for looking at it! > > > I will be bumping to 'Ready for Committer' unless objections. > > In that case, here is another patch that fixes a typo in the docs > mentioned privately to me by Erik. The typo (and a gratuitous rebase) > is the only change to what you just reviewed. Thank you. The typo was indistiguishable to me too. My :+1: stands for version 3 of the patch. Updating status in the commitfest to reflect that. //Georgios -- https://www.vmware.com > > ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- > > Vik Fearing
Commits
-
Use lfirst_int in cmp_list_len_contents_asc
- b822ae13ea93 14.0 landed
-
Fix misuse of foreach_delete_current().
- 1d581ce7129d 14.0 landed
-
Implement GROUP BY DISTINCT
- be45be9c33a8 14.0 landed