Column
Column Order
Reorders columns and can rename them at the same time through an alias.
When to use it
Use it to shape the final layout of a table before export, when you care about which columns appear first and what they are called.
In a pipeline
File InputColumn OrderExport Excel
Settings
| Setting | Type | Required | Default or hint |
|---|---|---|---|
| Column Order (JSON) | textarea | — | [{"name":"col1","alias":"Col 1"}] |
Example
Put the amount first and label the columns
- Column Order=Total as Amount, Order as Order ID
| Order | Region | Total |
|---|---|---|
| SO-1 | North | 120 |
| SO-2 | South | 340 |
| Amount | Order ID | Region |
|---|---|---|
| 120 | SO-1 | North |
| 340 | SO-2 | South |
Listed columns come first in the order given; Region was not listed, so it keeps its data and moves to the end.
Worth knowing
- This node never drops data. Columns you leave out are appended after the ones you listed; use Select Columns when you want them gone.
- Leave the alias empty to move a column without renaming it.
- It is a good last step before an export node, where header order is what the recipient sees.