Skip to content

Commit a886a09

Browse files
committed
Add overview of table operations to Cheat Sheet
Some table operations are arguably confusingly named, espcially for new nu users. Since the discussion in nushell/nushell#13779 didn't get much traction, at least there should be an easy to find an overview.
1 parent b829dfd commit a886a09

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

book/cheat_sheet.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,18 @@ $teams_scores | drop column
297297
# => ╰───┴───────────────────────┴───────╯
298298
```
299299

300+
### Overview of table operations
301+
302+
| part of table | keep | discard | add |
303+
|-|-|-|-|
304+
| specific rows | get | drop nth | - |
305+
| range of rows | slice | drop nth | - |
306+
| first n rows | first/take, take while, take until | skip, skip while, skip until | prepend |
307+
| last n rows | last | drop | append |
308+
| every nth row | every | every --skip | - |
309+
| specific columns | select | reject | insert plus move |
310+
| last n columns | - | drop column | insert |
311+
300312
## Files and Filesystem
301313

302314
open a text file with the default text editor:

0 commit comments

Comments
 (0)