Page tree



Contents:

The cloud-based version of Trifacta Wrangler is now available! Read all about it, and register for your free account.

NOTE: Transforms are a part of the underlying language, which is not directly accessible to users. This content is maintained for reference purposes only. For more information on the user-accessible equivalent to transforms, see Transformation Reference.

Removes the specified column or columns permanently from your dataset. 

Tips:

  • This transform might be automatically applied as one of the first steps of your recipe. See Initial Parsing Steps.
  • If you want to hide a column from view, select Hide from the column drop-down. Note that the data can still be referenced in your transforms and appears in any generated output. See Transformer Page.
  • If you are working with large datasets, you might want to delete columns at the beginning of your recipe, which can assist application and job execution performance. Use the tilde operator to specify ranges of columns.
  • You can also specify the columns that you wish to retain and then add the Keep action to delete all other columns in the dataset.

Basic Usage

Single-column example:

drop col:ThisOldColumn action: Drop

Output: Deletes the column named ThisOldColumn.

Multi-column example:

You can specify comma-separated sets of columns. 

drop col: FirstName, MiddleInitial action: Drop

Output: Deletes the columns FirstName and MiddleInitial from your dataset.

Keep example:

The following transform keeps the listed columns and deletes all others in the dataset:

drop col: FirstName, MiddleInitial action: Keep

Output: Dataset only contains FirstName and MiddleInitial columns.

Column range example:

You can also specify ranges of columns using the tilde (~) operator:

drop col:Column1~Column20 action: Drop

Output: Deletes the columns Column1 and Column20 and all columns displayed in between them in the data grid.

Parameters

drop col:column_ref action: [Drop|Keep]

TokenRequired?Data TypeDescription
dropYtransformName of the transform
colYstringName of the column or expression for columns to delete
actionYstringDrop or Keep the listed columns

For more information on syntax standards, see Language Documentation Syntax Notes.

col

Identifies the column or columns to which to apply the transform. You can specify one column or more columns.

To specify multiple columns:

  • Discrete column names are comma-separated. 
  • Values for column names are case-sensitive.

Usage Notes:

Required?Data Type
YesString (column name)

action

Identifies whether the action performed by the transformation:

  • Drop - Listed columns are deleted from the dataset.
  • Keep - Listed columns are retained in the dataset, and all other columns are deleted.

Usage Notes:

Required?Data Type
YesString (Drop or Keep)

Examples

See above.

 

Your Rating: Results: 1 Star2 Star3 Star4 Star5 Star 12 rates

This page has no comments.