Re: Boolean operators without commutators vs. ALL/ANY

From: Florian Pflug <fgp(at)phlo(dot)org>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, PG Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Boolean operators without commutators vs. ALL/ANY
Date: 2011-06-14 10:05:45
Message-ID: 0E1A7850-F26F-4391-9DBF-00341CE71686@phlo.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Jun13, 2011, at 16:19 , Andrew Dunstan wrote:
> On 06/13/2011 10:07 AM, Robert Haas wrote:
>> Some languages use =~ and some use just ~... I was just
>> wondering if anyone thought the commutator of =~ was ~=...
>
> My feeling is it's a bit dangerous. It's too easy to fat-finger the reverse op, and get something quite unintended.

Well, but with "~" you need to *remember* that the regexp
goes on the right side and the text on the left. That seems
worse than the risk of fat-fingering "=~" and getting "~=".

At, at least, have looked up the argument order of "~"
countless in the past...

best regards,
Florian Pflug

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Florian Pflug 2011-06-14 10:10:18 Re: Boolean operators without commutators vs. ALL/ANY
Previous Message Florian Pflug 2011-06-14 09:56:31 Re: [PATCH] Bug in XPATH() if expression returns a scalar value