renameColumns

The renameColumns method creates a new table with specified columns renamed.

Syntax

Parameters

ParameterTypeDescription
columnsString...

Columns that will be renamed in the new table.

  • "X = Y" will rename source column Y to X.
columnsCollection<String>

Columns that will be renamed in the new table.

  • "X = Y" will rename source column Y to X.
pairsMatchPair...

Columns that will be renamed in the new table.

  • "X = Y" will rename source column Y to X.

Returns

A new table that renames the specified columns.

Examples

The following example renames columns A and C: