Do you use PostGIS BRIN?
Paul Ramsey
pramsey at cleverelephant.ca
Tue Jan 7 16:27:09 PST 2025
> On Jan 7, 2025, at 4:21 PM, Tomas Vondra <tomas at vondra.me> wrote:
>
>> To what extent do you think we need those cross-type operators? box2df
>> is a stub type, and it is not creatable in SQL, to my knowledge, what
>> does having those op(geometry, box2df), op(box2df, box2df), etc, etc,
>> operators buy us?
>>
>
> Not sure, I'm not familiar with how these types are used, but I guess
> you need them if you support querying the geometry column using these
> other types.
Well, in the case of the GIST binding, I think we needed a “real” type to declare as the STORAGE for the opclass, but that type was just passed around as a pointer anyways, so effectively declaring the storage type as INTERNAL would have been just the same. I don’t think I had the moxie or the knowledge to try that at the time, so I just made a no-op type that is declared but has no working in/out functions and is never used as a parameter or return type in any function or operator.
So from that perspective, there would never be a box2df in existence to be passed into an operator(box2df, box2df), so those operator definitions are moot. I wonder if we can drop them or if they have some side effect on the index. If the index tests “does this geometry overlap this key” by calling the box2df && geometry operator.
P.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-devel/attachments/20250107/f32b53b8/attachment.htm>
More information about the postgis-devel
mailing list