Re: pgsql: Improve handling of NULLs in KNN-GiST and KNN-SP-GiST

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Erik Rijkers <er(at)xs4all(dot)nl>
Cc: Alexander Korotkov <akorotkov(at)postgresql(dot)org>, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Improve handling of NULLs in KNN-GiST and KNN-SP-GiST
Date: 2019-09-19 20:13:37
Message-ID: 2608.1568924017@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Erik Rijkers <er(at)xs4all(dot)nl> writes:
> Oops:
> create_index ... ok 634 ms
> create_index_spgist ... FAILED 438 ms
> create_view ... ok 329 ms

I'm betting the issue is breaking the Datum abstraction here:

- scan->xs_orderbyvals[i] = Float8GetDatum(distanceValues[i]);
+ scan->xs_orderbyvals[i] = item->distances[i].value;

AFAICS, item->distances[i].value is a double not a Datum, so dropping
the Float8GetDatum call is just wrong.

regards, tom lane

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Alexander Korotkov 2019-09-19 20:31:31 Re: pgsql: Improve handling of NULLs in KNN-GiST and KNN-SP-GiST
Previous Message Erik Rijkers 2019-09-19 19:49:19 Re: pgsql: Improve handling of NULLs in KNN-GiST and KNN-SP-GiST