Scenario: Standardizing French phone numbers - 6.1

Talend Components Reference Guide

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 Open Studio for Big Data
Talend Open Studio for Data Integration
Talend Open Studio for Data Quality
Talend Open Studio for ESB
Talend Open Studio for MDM
Talend Real-Time Big Data Platform
Talend Studio
Data Governance
Data Quality and Preparation
Design and Development

In this scenario, you use three components to standardize some French phone numbers according to the French phone number format.

The components to be used are:

  • tFixedFlowInput: this component is used to provide the input data composed of phone numbers to be processed and the French country code (FR).

  • tStandardizePhoneNumber: this component standardizes the phone numbers of interest.

  • tLogRow: this component displays the result of this standardization.

To replicate this scenario, proceed as the following sections illustrate:

Dropping and linking the components

To do this, proceed as follows:

  1. Drop tFixedFlowInput, tStandardizePhoneNumber and tLogRow from the Palette to the Design workspace.

  2. Right-click the tFixedFlowInput component to open the contextual menu and select Row > Main.

  3. Do the same to connect tStandardizePhoneNumber to tLogRow using a Row > Main link.

Then you can continue to configure these components.

Configuring the input data

To do this, proceed as follows:

  1. Double click tFixedFlowInput to open its Component view.

  2. Next to Edit schema, click the three-dot button to open the schema editor.

  3. Click the plus button to add two rows.

  4. In the Column column, rename these two newly added rows. In this scenario, name them phone and country respectively.

  5. Click OK to validate these changes and accept the propagation prompted by the dialog box that pops up.

  6. In the Mode area, select the Use Inline Table option to display the Inline Table.

  7. Under this table, click the plus button to add as much number of rows as you need. In this scenario, add 12 rows.

  8. In this table, type in, between quotation marks, phone numbers of various formats and the corresponding ISO 2-letter country code in the phone and the country columns respectively. In this scenario, they read as follows:

Configuring the standardization process

To do this, proceed as follows:

  1. Double click tStandardizePhoneNumber to open its Component view.

  2. If required, click Sync columns to retrieve the schema from the previous component.

  3. In the Phone number field, select phone from the drop-down list as this column holds the phone numbers to be processed.

  4. In the Country code field, select country from the drop-down list as this column provides the country code to be used. In this scenario, this code is the French country code FR.

  5. In the Phone number format for output field, select National as you need to standardize these phone numbers according to the national standard format of France.

Executing the Job

Press F6 to run this Job.

You can read the execution result in the console of the Run view.

From this result table, you can find that the first input record 0147045670, for example, is standardized as 01 47 04 56 70 according to the French phone number format and this number is of FIXED LINE.