col
function col(name): Column;Defined in: column.ts:383
Reference a column by name.
The name is left unresolved client-side and bound against the DataFrame
schema on the server at analysis time. If the column does not exist, the
server raises AnalysisException when the plan is executed.
Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
name | string | Column name; may be a simple identifier or a dotted path (for example "address.city") to reference a nested struct field. |
Returns
Section titled “Returns”Example
Section titled “Example”import { col, lit } from "@spark-connect-js/core";
df.filter(col("country").eq(lit("NL")));