Skip to main content Skip to complementary content

Extracting the delimited string column in the database table into multiple columns

Procedure

  1. Double-click tMysqlInput to open its Basic settings view.
  2. Fill the Host, Port, Database, Username, Password fields with the MySQL database connection information.
  3. Click the [...] button next to Edit schema and in the pop-up window define the schema of the tMysqlInput component same as the schema of the tMysqlOutput component.
  4. In the Table Name field, enter the name of the table into which the data was written. In this example, it is employee.
  5. Click the Guess Query button to fill the Query field with the SQL query statement to be executed on the specified table. In this example, it is as follows:
    SELECT 
      `employee`.`Id`, 
      `employee`.`Name`, 
      `employee`.`DelimitedField`
    FROM `employee`
  6. Double-click tExtractDelimitedFields to open its Basic settings view.
  7. In the Field to split list, select the delimited string column to be extracted. In this example, it is DelimitedField.
    In the Field separator, enter the separator used to separate the fields in the delimited string column. In this example, it is ,.
  8. Click the [...] button next to Edit schema and in the pop-up window define the schema by adding five columns: Id of Integer type, and Name, Age, Team, Title of String type.
    In this example, the delimited string column DelimitedField is split into three columns Age, Team and Title, and the Id and Name columns are kept as well.
    Click OK to close the schema editor and accept the propagation prompted by the pop-up dialog box.
  9. Double-click the second tLogRow to open its Basic settings view.
    In the Mode area, select Table (print values in cells of a table) for better readability of the result.

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!