Applying functions on multiple columns - 8.0

Talend Data Preparation User Guide

Version
8.0
Language
English
Product
Talend Big Data
Talend Big Data Platform
Talend Data Fabric
Talend Data Integration
Talend Data Management Platform
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Talend Real-Time Big Data Platform
Module
Talend Data Preparation
Content
Data Quality and Preparation > Cleansing data
Last publication date
2024-03-26

Rather than applying the same function to different columns one after the other, you can perform actions on several columns at the same time.

Let's take the example of a dataset containing several columns with date data, each of them set in a different format.

The different date formats used are the following:

  • dd/mm/yyyy for the Subscription date column
  • mm/dd/yyyy for the Last rental column
  • yyyy-mm-dd for the Birthday column

You are going to harmonize the date format, and set these columns to the French standard: dd/mm/yy.

Procedure

  1. Click the Subscription date column.
  2. To select the two remaining columns, you have two options:
    • While pressing the Ctrl key, click the Last rental column and the Birthday column.
    • While pressing the Shift key, select the Birthday column.

    The Shift + click option lets you select all the columns between your first selection and your last.

    When selecting multiple columns, no charts are available for the data.

  3. In the Functions panel, type Change Date Format.
  4. From the New format drop-down list, select French standard.
  5. Click Submit to apply the function on the three columns.

    You have the possibility to output the result of this function in a new column by selecting the Create new column check box.

Results

The date format for the three selected columns is now set to the French standard.

In addition, three new steps are added to the recipe, one for each column.