
Transform
CertifiedTransform typed records, variables, and Ion data.
Provide records, variables, or Ion files to filter, map, select, aggregate, unnest, or zip structured data with typed expressions, outputting transformed records or Ion data for downstream tasks.
Transform
Transform typed records, variables, and Ion data.
Provide records, variables, or Ion files to filter, map, select, aggregate, unnest, or zip structured data with typed expressions, outputting transformed records or Ion data for downstream tasks.
tasks
How to use the Transform plugin
These tasks let you reshape, filter, combine, flatten, and summarize structured data without writing custom code. They work both with in-memory records and with stored Ion files, so the same tasks can be used for small workflow variables and larger streamed datasets.
Common Inputs And Outputs
Most tasks accept records directly or as a stored Ion file.
from: used by tasks that read a single input, such asMap,Filter,Unnest, andAggregateinputs: used by tasks that read multiple inputs, such asSelectandZip
These inputs can typically be:
- a list of records from a previous task output or variable
- a single structured value that can be treated as a record
- a stored Ion file URI
Most tasks also share the same output options:
outputType: AUTO: return records for in-memory input, or store the result when the input is already a stored Ion fileoutputType: RECORDS: return records directly in the task outputoutputType: STORE: write the result to internal storage and return a URIoutputFormat: chooseTEXTorBINARYwhen writing Ion output
Common error handling options are also shared across several tasks:
FAIL: stop the task when an expression or transform step failsSKIP: drop the current record or row and continue- some tasks also support task-specific modes such as
KEEPforFilteror row-length and field-conflict handling forSelectandZip
Common Expression Language
Map, Filter, Select, and Unnest share the same per-record expression language.
Use it to read fields, navigate nested data, compute values, and write filter conditions.
Field Access
Use dot notation for regular fields:
user.idcustomer.address.city
Use bracket notation when a field name contains spaces or special characters:
user["first name"]$1["event type"]
Arrays
Use array indexes to read a specific element:
items[0]orders[1].total
Use [] to expand an array and work with all of its elements:
items[].priceorders[].lines[].sku
This is especially useful with functions such as sum, count, min, and max.
Literals And Operators
Supported literals:
- numbers:
1,3.14 - strings:
"paid" - booleans:
true,false - null:
null
Supported operators:
- boolean:
&&,||,! - comparison:
==,=,!=,>,>=,<,<=,in (...) - arithmetic:
+,-,*,/
Use == as the primary equality operator in examples and docs. A single = is also accepted as an alias for equality.
Use in (...) for membership checks against an explicit list of candidate values.
Parentheses can be used to control precedence:
(is_active || is_trial) && total_spent > 100sum(items[].price) / count(items[].price)country in ("FR", "DE", "AT")
Shared Functions
The shared expression language supports these functions:
toInt(value): convert a single scalar value to an integertoDecimal(value): convert a single scalar value to a decimal numbertoString(value): convert a single scalar value to a stringtoBoolean(value): convert a single scalar value to a booleanparseTimestamp(value): parse an Ion timestamp or an ISO-8601 timestamp string accepted by JavaInstant.parse, such as2024-02-01T12: 00: 00Z,2024-02-01T12: 00: 00.123Z, or2024-02-01T13: 00: 00+01: 00sum(values): aggregate numeric values from an array or expanded field path such asitems[].priceavg(values): return the average of numeric values from an array or expanded field pathcount(values): count values from an array or expanded field pathmin(values): return the minimum value from a comparable array or expanded field pathmax(values): return the maximum value from a comparable array or expanded field pathcoalesce(v1, v2, ...): return the first non-null value from one or more scalar expressionsconcat(v1, v2, ...): concatenate one or more scalar expressions as strings
Examples:
toDecimal(amount)coalesce(country, "unknown")concat(first_name, " ", last_name)sum(items[].price)
Positional Inputs In Select
Select works on multiple row-aligned inputs and also supports positional references:
$1,$2,$3, ...
Example:
$1.amount > 100 && $2.status == "active"
Use positional references when you want to distinguish fields coming from different aligned inputs.
Aggregate Expressions
Aggregate does not use the same per-record expression language for its aggregate definitions. Its aggregates entries use aggregate expressions instead:
count()sum(total)min(score)max(score)avg(duration)first(status)last(status)
Use the shared expression language for per-record transforms and conditions. Use aggregate expressions when summarizing grouped records.