Skip to main content
Version: 0.9.1

Expr.eq_missing

def eq_missing(other: Any) -> Expr

Categories: logic

Compare if 2 expressions are equal an, equivalent to expr == other. If one of the expressions is null (None) it returns false.

Parameters

parameter
other

The value to compare with.

Examples

>>> import tabsdata as td
>>>
>>> tf: td.TableFrame ...
>>>
>>> tf = tf.select(td.col("a").eq(td.col("b")).alias("eq_missing"))
>>>
┌─────┬──────┬───────────┐
│ a ┆ b ┆ eq_missing│
---------
│ f64 ┆ f64 ┆ bool
╞═════╪══════╪═══════════╡
1.02.0 ┆ false │
2.02.0 ┆ true │
│ NaN ┆ NaN ┆ true │
4.0 ┆ NaN ┆ false │
5.0 ┆ null ┆ false │
│ null┆ null ┆ true │
└─────┴──────┴───────────┘