# save-list command

The save-list command writes the list
of item-IDs generated by a select, sselect, qselect, or get-list command.

**Synonyms:** sl

## Syntax

```
save-list {{file.reference} {list.name}}
```

## Parameter(s)

| save-list | Must be invoked immediately after the command that created the list. |
| --- | --- |
| file.reference | Specifies a file in which to save the list. If not specified, the list is saved in the pointer-file. |
| list.name | Specifies the name of the list-item. If there is already an item with the specified item-ID, it automatically is overwritten by the new list. If not specified, the default name, %user-ID, is used. |

## Example(s)

```
sselect entity with area.code "714" by name

[404] 16782 items selected out of 272876 items.

save-list orange.county

List ’orange.county’ in ’pointer-file’ saved.
```

## See also

- [Active list](https://d3codex.com/definitions/active-list/)
- [compare-list command](https://d3codex.com/tcl/compare-list-command/)
- [copy-list command](https://d3codex.com/tcl/copy-list-command/)
- [delete-list command](https://d3codex.com/tcl/delete-list-command/)
- [edit-list command](https://d3codex.com/tcl/edit-list-command/)
- [fl command](https://d3codex.com/tcl/fl-command/)
- [get-list command](https://d3codex.com/tcl/get-list-command/)
- [list-lists macro](https://d3codex.com/tcl/list-lists-macro/)
- [pointer-file file](https://d3codex.com/systemfiles/pointer-file-file/)
- [qselect command](https://d3codex.com/tcl/qselect-command/)
- [Secondary list](https://d3codex.com/definitions/secondary-list/)
- [nselect command](https://d3codex.com/access/nselect-command/)
- [sort-list command](https://d3codex.com/tcl/sort-list-command/)
- [u0195 user exit](https://d3codex.com/proc/u0195-user-exit/)

---
Source: https://d3codex.com/tcl/save-list-command/ - part of the D3Codex reference.
