Skip to main content
  • New archived content: Talend MDM, Talend Data Catalog 8.0, and Talend 7.3 products reached their end of life in 2024. Their documentation was moved to the Talend Archive page and will no longer receive content updates.
Close announcements banner

Outputting blank values as null or fixed values

You can output blank values as null or fixed values using expressions.

To output blank values of a column as null, use the following expression syntax:

rowName.columnName.equals("")?null:rowName.columnName

To output blank values of a column as fixed values, use the following expression syntax:

rowName.columnName.equals("")?fixValue:rowName.columnName

In the following example, any blank values in the name column will be replaced with null; any blank values in the company column will be replaced with the string Unknown.

The following two tables show the input and output of a tMap component with these two expressions applied.

Input table:

id name company
1 John Talend
2   Apple
3 Jane  

Output table:

id name company
1 John Talend
2 null Apple
3 Jane Unknown

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!