User defined Java Expression
Description
User Defined Java Expression calculates new field values within a data stream using custom Java expressions. Use this step when you need the performance and type safety of Java for inline calculations without writing a full Java class — for example, performing type conversions, calling Java string methods, or applying mathematical functions. Each expression produces a new output field, making this step a lightweight alternative to User Defined Java Class for simpler transformation needs.
Configurations
| Field Name | Description |
|---|---|
| Step name | Specify the name of the step as it appears in the workflow workspace. This name has to be unique in a single workflow. |
| New Field | The new field in the data stream. If you want to overwrite an existing field, you need to define the field here and in the "Replace value" option. |
| Java Expression | Specify the Java Expression |
| Value Type | Specify the data type. |
| Length | For Number: Total number of significant figures in a number; For String: total length of string; For Date: length of printed output of the string. Specify the length, - For Number: Total number of significant figures in a number - For String: total length of string - For Date: length of printed output of the string. |
| Precision | For Number: Number of floating point digits; For String, Date, Boolean: unused. No. of digits after decimal. Specify the precision, - For Number: Number of floating point digits; - For String, Date, Boolean: unused. |
| Replace value | Select a field from the drop down list when you want to replace a field. |