Repository navigation
Give each topological operator its SQL names by class - #187
Merged
estebanzimanyi merged 1 commit intoOct 10, 2026
Merged
estebanzimanyi merged 1 commit into
estebanzimanyi merged 1 commit into
Conversation
The topological operators &&, @>, <@ and -|- have one SQL name per class of their operands, as the position operators have: MobilityDB names the functions behind them by the class they compare, && being setOverlaps, spanOverlaps, spansetOverlaps, tboxOverlaps, stboxOverlaps and tpcboxOverlaps, a temporal operand taking the class of its bounding box. No operator of MobilityDB master is backed by a function named overlaps, contains, contained or adjacent: its one contains, contains(geometry, geometry), is the spatial relationship, which carries no operator and which Spark and Flink call geoContains. The mapping holds them under positionFamilies as the family topology, each operator with its stem overlaps, contains, contained or adjacent, and not as bare names under families, so byOperator and byBareName carry 21 pairs and byPositionOperator 20 operators. attach_position_names derives their names from the @sqlfn tags of the functions whose @sqlop is the operator, as it derives the position names, and stops the pipeline on a tag that is not the class followed by the stem, such as a shared contains_bbox tag. classify_backing_sqlfn flags the shared backing tag of a bare name, which ~= alone has; MobilityDB master carries no such tag. The parity audit lists the four under byPosition, backed by the MEOS functions their stem prefixes (overlaps_*, contains_*), and the documentation, the schema description and the cross-repository handoff state the topological operators beside the position ones. Measured over MobilityDB master 96d665686e: run.py derives 88 names by class for the 20 operators, 24 of them topological: setOverlaps … tpcboxOverlaps, the seven @> names including tjsonbContains, the six <@ names and the five -|- names, each one a function MobilityDB master's .in.sql files declare. portable_parity.py reads 41 of 41 operators backed. The suite collects 534 tests, the portable ones pass with none skipped, and the floor of .github/workflows/pytest.yml stays 534. JMEOS's Spark UDF surface, generated from this catalog, registers none of the bare overlaps, contains, contained and adjacent, of which contains would replace Spark's own function; its typed Spark and Flink SQL surfaces are unchanged. Why: a binding registers what the catalog states, and the catalog states the names MobilityDB declares for these operators.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The topological operators &&, @>, <@ and -|- have one SQL name per class of their operands, as
the position operators have: MobilityDB names the functions behind them by the
class they compare, && being setOverlaps, spanOverlaps, spansetOverlaps, tboxOverlaps,
stboxOverlaps and tpcboxOverlaps, a temporal operand taking the class of its bounding box. No
operator of MobilityDB master is backed by a function named overlaps, contains, contained or
adjacent: its one contains, contains(geometry, geometry), is the spatial relationship, which
carries no operator and which Spark and Flink call geoContains. The mapping
holds them under positionFamilies as the family topology, each operator with its stem overlaps,
contains, contained or adjacent, and not as bare names under families, so byOperator and
byBareName carry 21 pairs and byPositionOperator 20 operators. attach_position_names derives
their names from the @sqlfn tags of the functions whose @sqlop is the operator, as it derives the
position names, and stops the pipeline on a tag that is not the class followed by the stem, such
as a shared contains_bbox tag. classify_backing_sqlfn flags the shared backing tag of a bare
name, which ~= alone has; MobilityDB master carries no such tag.
The parity audit lists the four under byPosition, backed by the MEOS functions their stem
prefixes (overlaps_, contains_), and the documentation, the schema description and the
cross-repository handoff state the topological operators beside the position ones.
Measured over MobilityDB master 96d665686e: run.py derives 88 names by class for the 20
operators, 24 of them topological: setOverlaps … tpcboxOverlaps, the seven @> names including
tjsonbContains, the six <@ names and the five -|- names, each one a function MobilityDB
master's .in.sql files declare. portable_parity.py reads 41 of 41 operators backed. The suite
collects 534 tests, the portable ones pass with none skipped, and the floor of
.github/workflows/pytest.yml stays 534. JMEOS's Spark UDF surface, generated from this catalog,
registers none of the bare overlaps, contains, contained and adjacent, of which contains
would replace Spark's own function; its typed Spark and Flink SQL surfaces are unchanged.
Why: a binding registers what the catalog states, and the catalog states the names MobilityDB
declares for these operators.