Re: bit|varbit #, xor operator - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: bit|varbit #, xor operator
Date
Msg-id 53e94f95-fe3f-d238-128d-d8b2d3f2a762@BlueTreble.com
Whole thread Raw
In response to Re: bit|varbit #, xor operator  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: bit|varbit #, xor operator  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 10/16/16 3:13 PM, Tom Lane wrote:
> As for counting bits in a bitstring, why do we have to make that an
> operator at all?  Using a function would decrease the stress involved
> in choosing a name, and it's hard to believe that the requirement is
> so common that we need to shave a few keystrokes.  But if you must have
> an operator there's not that much wrong with using prefix # for it.

Fair enough.

>> > Related to this I'd also like to add a boolean XOR operator as that's a
>> > relatively common request/question.
> We have boolean XOR; it's spelled "<>".

I always forget about that... though, it doesn't work for boolean arrays.
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com
855-TREBLE2 (855-873-2532)   mobile: 512-569-9461



pgsql-hackers by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: [COMMITTERS] pgsql: Replace PostmasterRandom() with a stronger way of generating ran
Next
From: Tom Lane
Date:
Subject: Re: bit|varbit #, xor operator