Re: [GENERAL] 9.5 "chained equality" behavior

2017-05-30 Thread David G. Johnston
On Tue, May 30, 2017 at 2:32 PM, David G. Johnston < david.g.johns...@gmail.com> wrote: > ​...​ > namely because aside from equality all of the comparison operators > convert their inputs to a boolean and so cannot be placed in sequence like > shown here (boolean compared to, say, integer doesn't

Re: [GENERAL] 9.5 "chained equality" behavior

2017-05-30 Thread David G. Johnston
On Tue, May 30, 2017 at 1:56 PM, Joshua Ma wrote: > Our team is upgrading from 9.4 to 9.5, and we noticed this behavior change: > > 9.4: > # SELECT true = true = true; > ?column? > -- > t > (1 row) > > 9.5: > # SELECT true = true = true; > ERROR: syntax error at or near "=" > LINE 1: S

Re: [GENERAL] 9.5 "chained equality" behavior

2017-05-30 Thread Tom Lane
Joshua Ma writes: > Our team is upgrading from 9.4 to 9.5, and we noticed this behavior change: > 9.5: > # SELECT true = true = true; > ERROR: syntax error at or near "=" > LINE 1: SELECT true = true = true; > Now, there's actually a larger problem with this, since it's not actually > chained eq

Re: [GENERAL] 9.5 "chained equality" behavior

2017-05-30 Thread Thomas Kellerer
Joshua Ma schrieb am 30.05.2017 um 22:56: We're going to fix usages of this to instead do (a = b && a = c) instead of (a = b = c). That has to be (a = b AND a = c) The && operator is not valid for booleans -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make chan

[GENERAL] 9.5 "chained equality" behavior

2017-05-30 Thread Joshua Ma
Our team is upgrading from 9.4 to 9.5, and we noticed this behavior change: 9.4: # SELECT true = true = true; ?column? -- t (1 row) 9.5: # SELECT true = true = true; ERROR: syntax error at or near "=" LINE 1: SELECT true = true = true; Now, there's actually a larger problem with this,