Skip to main content
This enricher type allows you to add custom transformation logic using CDAP’s extensive Wrangler Directives. The below listed are some of the commonly used directives, for more such directives that might suit your use case, refer to the GitHub help documentation.
Note:This transformation is applied to the Source column. Hence, for the Directive where the Source and Destination column name must be defined, ensure that it refers to your Source column name in both places.On clicking the below links, you are redirected to the relevant GitHub help documentation for directive code examples and references.
DIRECTIIVESDESCRIPTION
Parsers
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/json-path.mdIt uses a DSL (a JSON path expression) for parsing JSON records.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/parse-as-currency.mdIt is used to parse a string representation of currency into a number.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/parse-as-datetime.mdIt is used to parse strings with DateTime values to CDAP DateTime type.
Transformations
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/changing-case.mdIt is used to change the case of column values.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/cut-character.mdIt selects parts of a string value.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/set-column.mdIt sets the column value to the result of an expression execution.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/find-and-replace.mdIt is used to transform the string column values using a sed-like expression.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/quantize.mdIt quantises a column based on the specified ranges.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/extract-regex-groups.mdIt extracts the data from a regex group into its own column.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/set-charset.mdIt sets the encoding and then converts the data to a UTF-8 string.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/split-by-separator.mdIt splits a column into two columns based on a separator.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/split-url.mdIt splits a URL into its constituents.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/text-distance.mdIt measures the difference between the two sequences of characters.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/text-metric.mdIt measures the difference between the two sequences of characters
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/url-decode.mdIt decodes from the application/x-www-form-urlencoded MIME format.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/url-encode.mdIt encodes to the application/x-www-form-urlencoded MIME format.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/trim.mdIt is used to trim the white spaces around string data.
Encoders and Decoders
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/decode.mdIt decodes a column value as one of base32, base64 or hex.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/encode.mdIt encodes a column value as one of base32, base64 or hex.
Date Transformations
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/diff-date.mdIt calculates the difference between two dates.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/format-date.mdIt is used for custom date-time formatting patterns.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/format-unix-timestamp.mdIt formats a UNIX timestamp as a date.
DateTime Transformations
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/current-datetime.mdIt generates the current DateTime using the given zone or UTC, by default.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/datetime-to-timestamp.mdIt converts a DateTime value to timestamp with the given zone.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/format-datetime.mdIt formats a DateTime value to custom date time pattern strings.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/timestamp-to-datetime.mdIt converts a timestamp value to DateTime.
Hashing & Masking
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/hash.mdIt generates a message digest.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/mask-number.mdIt applies substitution masking on the column values.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/mask-shuffle.mdIt applies shuffle masking on the column values.
Column Operations
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/merge.mdIt merges two columns by inserting a third column.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/swap.mdIt swaps the column names of two columns.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/set-type.mdIt converts the data type of a column.
Transient Aggregators & Setters
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/increment-variable.mdIt increments a transient variable with a record of processing.
https://github.com/data-integrations/wrangler/blob/develop/wrangler-docs/directives/set-variable.mdIt sets a transient variable with a record of processing.
Note:You cannot add Custom Transformer for the Country and ID fields. To know more about how to configure this enricher, refer to Configuring the Custom Transformer Enrichers.
Last modified on February 26, 2026