Change column type
Convert every value in a column to String, Number, DateTime or Boolean; empty cells stay empty.
Command in the Data Table toolkit · id ooa.datatable/change_column_type · 5 inputs (2 required), 1 output
Inputs
| Input | Type | Required | Default | What it is |
|---|---|---|---|---|
| Table | Table | Yes | Source table. | |
| Column | String | No | Column to convert. | |
| Type | String | Yes | Target type. | |
| Column index | Number | No | Zero-based column index; used when 'column' is empty. | |
| Date format | String | No | Pattern of the text when converting to DateTime, e.g. dd/MM/yyyy, or a ready format: ISO_DATE, ISO_LOCAL_DATE_TIME, ISO_OFFSET_DATE_TIME, BASIC_ISO_DATE, RFC_1123_DATE_TIME...; ISO dates when empty. |
Outputs
| Output | Type | What it is |
|---|---|---|
| table | Table | Updated table. |