Version: dev

distinct

Stable function · Relational keys and geometry

Tier: stable · Kind: function · Topic: Relational keys and geometry

JuliaTypeScriptPythonRustGo
not exportednot exporteddistinctdistinctnot exported

Julia

Julia does not export this function.

TypeScript

TypeScript does not export this function.

Python

distinct(rows: Iterable[Any]) -> list[Any]

Set semantics over rows: sort by the §5.5.1 total order, then drop adjacent duplicates (rule 2).

The returned order is the sorted order — never first-seen / set iteration order. A pure function of the input multiset, so duplicate, reversed, and permuted inputs all collapse to the identical output.

rows is any iterable of order-comparable keys: integer / categorical scalars, or tuples thereof (a list row is normalised to a tuple). Floats in keys raise FloatKeyError (rule 1). Mirrors the DuckDB oracle SELECT DISTINCT … ORDER BY ….

Source

Rust

pub fn distinct(rows: &[Key]) -> Vec<Key>

Set semantics over rows: sort by the §5.5.1 total order, then drop adjacent duplicates (rule 2). The returned order is the sorted order — never first-seen / insertion order. A pure function of the input multiset, so duplicate, reversed, and permuted inputs all collapse to the identical output.

Mirrors the DuckDB oracle SELECT DISTINCT … ORDER BY ….

Source · Rust docs

Go

Go does not export this function.