Splitting and Reordering Columns

Use this function to reorder the target split columns while splitting a column.

Suppose a project contains patients data from two sources, Source 1 and Source 2. In the DOB column, the birth dates of patients are in two different formats. In Source 1, the dates are in the M/d/yyyy format, and in Source 2, the dates are in the yyyy-MM-dd format.

Now, you want to split the DOB column into three columns: Year, Month, and Day. When splitting, you have to do some reordering for the dates in Source 1.

Procedure

  1. From the DOB column menu, click Edit columns > Split columns and reorder.
  2. In the Target column name field, enter a name of the column that the specified column is split into, ans then click Add. In this example, enter and add Year, Month, and Day one by one.
  3. Create a condition and select a splitting method for splitting dates in Source 2:
    1. In the Condition expression area, click Create.
    2. In the Expression field, enter cells['Source'].value=="2", and then click OK.
    3. Click Separator, and then enter a hyphen (-) in the field.
    4. In the Condition layout list area, click Add to add the condition.

      The created condition expression and selected splitting method are displayed in the Condition layout list panel.

  4. Create a condition, select a splitting method, and reorder target columns for splitting dates in Source 1:
    1. In the Condition expression area, click Create.
    2. In the Expression field, enter cells['Source'].value=="1", and then click OK.
    3. Click Separator, and then enter a forward slash (/) in the field.
    4. Click Reorder to reorder the target columns. In the Reorder Columns dialog, drag the split columns to reorder according to the M/d/yyyy format. Click OK.
    5. In the Condition layout list area, click Add to add the condition. Click OK.

Result

The DOB column is spited into three columns: Year, Month, and Day.