Split fields to rows
Description
The Split Fields To Rows transform splits a row containing a delimited field into multiple new rows, one per split value.
Usage
The original row is not delivered to following transforms.
By default the original field is left in each new row to assist in debugging or error handling. Enable Exclude field to split from output to drop that field from the output rows. It can also be removed with a Select Values transform.
The original field must be a string field.
A new field name must be specified.
If the value type/format of the new row is not specified, the new field will use the same type/format as the original field.
Examples
-
Delimiter Regular Expression to split on a comma, or a space, or a comma + space (* n):
[,\s]\s* -
Enclosure to keep commas inside quoted values: delimiter
and enclosure,turns"into three rows:hi,"hello, world","hey",hi,hello, world.hey
Options
| Option | Description |
|---|---|
Transform name |
Name of the transform. |
Field to split |
The field you want to split. |
Exclude field to split from output |
When enabled, the field to split is removed from each output row. The split values are still written to the new field. Disabled by default, so existing pipelines keep the original field. |
Delimiter |
The delimiter or separator used. Special characters (e.g. CHAR ASCII HEX01) can be set with the format $[value], e.g. $[01] or $[6F,FF,00,1F]. |
Enclosure |
Optional enclosure string. Delimiters inside a pair of enclosure characters are not treated as split points, and the enclosure characters are removed from the output values.
For example with a comma (,) delimiter: |
Delimiter is a Regular Expression |
The regular expression to match the delimiter. |
New field name |
The name of the new field. |