Re: Crash in BRIN minmax-multi indexes - Mailing list pgsql-hackers

From Tomas Vondra
Subject Re: Crash in BRIN minmax-multi indexes
Date
Msg-id b0e6d18c-9cd4-6639-271e-71c211b32ed8@enterprisedb.com
Whole thread Raw
In response to Re: Crash in BRIN minmax-multi indexes  (Tomas Vondra <tomas.vondra@enterprisedb.com>)
List pgsql-hackers
BTW, for the inet data type, I considered simply calling the "minus"
function, but that does not work because of this strange behavior:


int4=# select '10.1.1.102/32'::inet > '10.1.1.142/24'::inet;
 ?column?
----------
 t
(1 row)

int4=# select '10.1.1.102/32'::inet - '10.1.1.142/24'::inet;
 ?column?
----------
      -40
(1 row)


That is, (a>b) but then (a-b) < 0. AFAICS it's due to comparator
considering the mask, while the minus ignores it. I find it a bit
strange, but I assume it's intentional.


regards

-- 
Tomas Vondra
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: Crash in BRIN minmax-multi indexes
Next
From: Anton Voloshin
Date:
Subject: Re: possible repalloc() in icu_convert_case()