Skip to content

Expose minDistance scalar UDFs#135

Open
estebanzimanyi wants to merge 1 commit into
fix/bump-meos-pinfrom
feat/mindistance-udf-udaf-scaffold
Open

Expose minDistance scalar UDFs#135
estebanzimanyi wants to merge 1 commit into
fix/bump-meos-pinfrom
feat/mindistance-udf-udaf-scaffold

Conversation

@estebanzimanyi
Copy link
Copy Markdown
Member

Registers minDistance(tgeompoint, geometry), minDistance(geometry, tgeompoint), and minDistance(tgeompoint, tgeompoint) following the nearestApproachDistance pattern. The geo-typed forms reuse the NAD kernel since NAD reduces to spatial-min when one argument has no time dimension; the tgeompoint/tgeompoint form calls the threshold-aware mindistance_tgeo_tgeo kernel. The canonical cross-join shape is MIN(minDistance(t1, t2)) with GROUP BY, the cloud-SQL-natural Solution-2 form, identical in result to the MobilityDB 2-ary aggregate of the same signature. Stacked on the MEOS pin bump branch; advances the pin one further commit to d4cc7d289 so the mindistance kernels are present, a commit that only adds mindistance_tgeo_tgeo and tgeoarr_tgeoarr_mindist and changes no existing signature.

@estebanzimanyi
Copy link
Copy Markdown
Member Author

Reviewer's quickstart — ~2-3 minutes

What this PR does: Expose minDistance scalar UDFs.

Risk: focused, single-purpose. Spot-check the source diff + matching tests; CI confirms.

Cross-link: Linux arm64 CI here needs #161 for the orthogonal MeosType build error.

@estebanzimanyi estebanzimanyi force-pushed the feat/mindistance-udf-udaf-scaffold branch from 2cc3079 to a815913 Compare May 29, 2026 21:38
@estebanzimanyi estebanzimanyi changed the base branch from fix/bump-meos-pin to fix/bump-meos-pin-wasm-pgconfig May 30, 2026 06:29
@estebanzimanyi estebanzimanyi changed the base branch from fix/bump-meos-pin-wasm-pgconfig to fix/bump-meos-pin May 30, 2026 07:00
@estebanzimanyi estebanzimanyi force-pushed the fix/bump-meos-pin branch 4 times, most recently from fa2de57 to 17588c0 Compare June 2, 2026 09:47
@estebanzimanyi estebanzimanyi force-pushed the feat/mindistance-udf-udaf-scaffold branch from a815913 to ca20a89 Compare June 5, 2026 17:07
@estebanzimanyi estebanzimanyi force-pushed the feat/mindistance-udf-udaf-scaffold branch from ca20a89 to 3051e8f Compare June 5, 2026 17:15
Registers minDistance(tgeompoint, geometry), minDistance(geometry,
tgeompoint), and minDistance(tgeompoint, tgeompoint) following the
nearestApproachDistance pattern. The geo-typed forms reuse the NAD
kernel since NAD reduces to spatial-min when one argument has no time
dimension; the tgeompoint/tgeompoint form calls the threshold-aware
mindistance_tgeo_tgeo kernel. The canonical cross-join shape is
MIN(minDistance(t1, t2)) with GROUP BY, the cloud-SQL-natural Solution-2
form; MobilityDB exposes the same signature as a 2-ary aggregate and
yields identical results. Advances the MEOS vcpkg pin one commit over
the base branch to d4cc7d289 so the mindistance kernels are present;
that commit only adds mindistance_tgeo_tgeo and tgeoarr_tgeoarr_mindist
and changes no existing signature.
@estebanzimanyi estebanzimanyi force-pushed the feat/mindistance-udf-udaf-scaffold branch from 3051e8f to f0b9b6c Compare June 5, 2026 18:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant