Skip to content

Commit

Permalink
Remove non-functional example command and fix other one (#5272)
Browse files Browse the repository at this point in the history
[Preview](https://docs-getdbt-com-git-dbeatty10-patch-1-dbt-labs.vercel.app/reference/node-selection/syntax)

## What are you changing in this pull request and why?

Noticed a couple code examples that won't work as-is, so fixed them by
removing:
- double quotes surrounding all the CLI flags
- `--defer` flag for `ls` command

## Checklist
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
so my content adheres to these guidelines.
  • Loading branch information
dbeatty10 authored Apr 16, 2024
1 parent bf87975 commit 01fffea
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions website/docs/reference/node-selection/syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ Constructing and debugging your selection syntax can be challenging. To get a "
dbt ls --select "path/to/my/models" # Lists all models in a specific directory.
dbt ls --select "source_status:fresher+" # Shows sources updated since the last dbt source freshness run.
dbt ls --select state:modified+ # Displays nodes modified in comparison to a previous state.
dbt ls --select "result:<status>+ state:modified+ --defer --state ./<dbt-artifact-path>" # Lists nodes that match certain [result statuses](/reference/node-selection/syntax#the-result-status) and are modified.
dbt ls --select "result:<status>+" state:modified+ --state ./<dbt-artifact-path> # Lists nodes that match certain [result statuses](/reference/node-selection/syntax#the-result-status) and are modified.
```

<Snippet path="discourse-help-feed-header" />
Expand Down Expand Up @@ -186,7 +186,7 @@ After issuing one of the above commands, you can reference the results by adding

```bash
# You can also set the DBT_STATE environment variable instead of the --state flag.
dbt run --select "result:<status> --defer --state path/to/prod/artifacts"
dbt run --select "result:<status>" --defer --state path/to/prod/artifacts
```

The available options depend on the resource (node) type:
Expand All @@ -205,7 +205,7 @@ The available options depend on the resource (node) type:
The state and result selectors can also be combined in a single invocation of dbt to capture errors from a previous run OR any new or modified models.

```bash
dbt run --select "result:<status>+ state:modified+ --defer --state ./<dbt-artifact-path>"
dbt run --select "result:<status>+" state:modified+ --defer --state ./<dbt-artifact-path>
```

### Fresh rebuilds
Expand Down

0 comments on commit 01fffea

Please sign in to comment.