2022-02-14 03:22:51 +01:00
|
|
|
---
|
|
|
|
title: move
|
|
|
|
layout: command
|
2022-03-04 13:10:09 +01:00
|
|
|
version: 0.59.1
|
2022-02-14 03:22:51 +01:00
|
|
|
---
|
2021-05-30 02:57:04 +02:00
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
Move columns before or after other columns
|
|
|
|
|
|
|
|
## Signature
|
|
|
|
|
|
|
|
```> move ...columns --after --before```
|
2021-05-30 02:57:04 +02:00
|
|
|
|
|
|
|
## Parameters
|
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
- `...columns`: the columns to move
|
|
|
|
- `--after {string}`: the column that will precede the columns moved
|
|
|
|
- `--before {string}`: the column that will be the next after the columns moved
|
2021-05-30 02:57:04 +02:00
|
|
|
|
|
|
|
## Examples
|
2022-02-14 03:22:51 +01:00
|
|
|
|
|
|
|
Move a column before the first column
|
2021-05-30 02:57:04 +02:00
|
|
|
```shell
|
2022-02-14 03:22:51 +01:00
|
|
|
> [[name value index]; [foo a 1] [bar b 2] [baz c 3]] | move index --before name
|
|
|
|
```
|
2021-05-30 02:57:04 +02:00
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
Move multiple columns after the last column and reorder them
|
2021-05-30 02:57:04 +02:00
|
|
|
```shell
|
2022-02-14 03:22:51 +01:00
|
|
|
> [[name value index]; [foo a 1] [bar b 2] [baz c 3]] | move value name --after index
|
|
|
|
```
|
2021-05-30 02:57:04 +02:00
|
|
|
|
2022-02-14 03:22:51 +01:00
|
|
|
Move columns of a record
|
2021-05-30 02:57:04 +02:00
|
|
|
```shell
|
2022-02-14 03:22:51 +01:00
|
|
|
> { name: foo, value: a, index: 1 } | move name --before index
|
|
|
|
```
|