Ashutosh Bapat <ashutosh.bapat@enterprisedb.com> writes:
> I am fine with the patch. It introduces a lot of expected output diff,
> since we always deparse GROUP BY clause in positional notation. That's
> fine. There is no point in adding extra logic to use positional
> notation only when there are duplicate entries in the GROUP BY clause.
Yeah, agreed, particularly since that behavior has only been there since
10.0 anyway. Pushed with a few cosmetic adjustments (mostly, improving
shaky English in the comments in foreign_grouping_ok()).
regards, tom lane