Skip to main content

Copy Column Values

The Copy Column Values task copies values from a given column to a new Column.

When to use

  • To create a backup of a column's values.
  • To copy values from one column into another.
  • To copy values from a column based on a criterion.

Quickstart

Let us start with the following sample data:

StudentScienceEnglishFrench
Alice140138
Bob135145
Frank122102
Judy185135

In this sample data, it is evident that the student takes only one of the two language subjects. Our goal is to consolidate the values of English and French columns into a new column named Language

StudentScienceEnglishFrenchLanguage
Alice140138138
Bob135145145
Frank122102102
Judy185135135

Following are the steps to achieve our goal:

  1. Go to Transform > Column Functions.
  2. Select the Copy Column Values function.
  3. Choose the column English and add a condition that says English has Non Empty Values
  4. Enter Language in the new column and hit APPLY. This will create a new column called Language and fill in the values from column English into column language wheresoever it has a value
  5. Open Data Preparation menu and click on Column Function
  6. Select Copy Column Values
  7. Choose the language French and add a condition that says French has Non Empty Values
  8. Select the column Language in result section and hit APPLY
note

English and French can be removed by deleting columns

The resulting data should now look like below:

StudentScienceLanguage
Alice140138
Bob135145
Frank122102
Judy185135

Supported Options

This task takes the following inputs:

  • Copy from: The column from which you want to copy values from.
  • Condition: See Condition
note

You can copy a numeric column or a date column as a text column. This will set the format on the date/numeric columns to as seen currently on the grid. It cannot be edited later and will not reflect even if you change the format.

info
  1. Result: The result column documentation.
  2. Date formatting: The date formatter documentation