Less-than and greater-than use exact same-type order.

highlighted = computed this step

Ordered comparisons

Less-than and greater-than compare exact same-type values.

< and >\text{< and >}

Greater than

The greater-than example keeps 1 row.

gt TRUE=1\text{gt TRUE}=1

Comparison examples are tiny finite-table transforms with SQL-style TRUE/FALSE/UNKNOWN results; SQL dialect completeness, type coercion, optimizer behavior, indexing, and product claims are out of scope.

Greater-than comparison: base rowsidnameqtycity1alpha3Austin2beta7Boston3gamma7NULL4delta10Denver5epsilonNULLAustin Comparison result per rowsourceleftValueoprightValuetruthoutputRole03gt7FALSEdropped17gt7FALSEdropped27gt7FALSEdropped310gt7TRUEkept4NULLgt7UNKNOWNdropped WHERE-style TRUE-only output rowsidnameqtycity4delta10Denver Comparison factsfactvalueinputRowCount5trueCount1falseCount3unknownCount1outputRowCount1droppedRowCount4orderedComparisonyeswhereKeepsTRUE_only_source_order

Less than

The less-than example keeps 3 rows.

lt TRUE=3\text{lt TRUE}=3

Comparison examples are tiny finite-table transforms with SQL-style TRUE/FALSE/UNKNOWN results; SQL dialect completeness, type coercion, optimizer behavior, indexing, and product claims are out of scope.

Less-than comparison: base rowsidnameqtycity1alpha3Austin2beta7Boston3gamma7NULL4delta10Denver5epsilonNULLAustin Comparison result per rowsourceleftValueoprightValuetruthoutputRole03lt8TRUEkept17lt8TRUEkept27lt8TRUEkept310lt8FALSEdropped4NULLlt8UNKNOWNdropped WHERE-style TRUE-only output rowsidnameqtycity1alpha3Austin2beta7Boston3gamma7NULL Comparison factsfactvalueinputRowCount5trueCount3falseCount1unknownCount1outputRowCount3droppedRowCount2orderedComparisonyeswhereKeepsTRUE_only_source_order

Summary

Ordered comparisons are exact here; performance, indexes, and type coercion are outside the model.

exact ordered check\text{exact ordered check}