Skip to content

Commit

Permalink
Update sl-snowflake-qs.md (#5947)
Browse files Browse the repository at this point in the history
the entity name for the Orders model does not allign with the entity
name from the Customers model. The metric Large Order does not use the
correct syntax and thus cannot be used by the BI tool downstream

## What are you changing in this pull request and why?
Modifying code snippets for `fct_orders.yml` to ensure that the
customers entity is aligned with `dim_customers`
Fixing code snippet for the filters param of Large Orders.

## Checklist
<!--
Uncomment when publishing docs for a prerelease version of dbt:
- [ ] Add versioning components, as described in [Versioning
Docs](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-entire-pages)
- [ ] Add a note to the prerelease version [Migration
Guide](https://github.com/dbt-labs/docs.getdbt.com/tree/current/website/docs/docs/dbt-versions/core-upgrade)
-->
- [ ] 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.
- [ ] For [docs
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#about-versioning),
review how to [version a whole
page](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
and [version a block of
content](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-blocks-of-content).
- [ ] Add a checklist item for anything that needs to happen before this
PR is merged, such as "needs technical review" or "change base branch."

Adding or removing pages (delete if not applicable):
- [ ] Add/remove page in `website/sidebars.js`
- [ ] Provide a unique filename for new pages
- [ ] Add an entry for deleted pages in `website/vercel.json`
- [ ] Run link testing locally with `npm run build` to update the links
that point to deleted pages

Co-authored-by: Mirna Wong <[email protected]>
Co-authored-by: Matt Shaver <[email protected]>
  • Loading branch information
3 people authored Aug 27, 2024
1 parent 52faa0b commit 2c0909c
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions website/docs/guides/sl-snowflake-qs.md
Original file line number Diff line number Diff line change
Expand Up @@ -661,7 +661,8 @@ semantic_models:
entities:
- name: order_id
type: primary
- name: customer_id
- name: customer
expr: customer_id
type: foreign
```
Expand All @@ -686,8 +687,9 @@ semantic_models:
entities:
- name: order_id
type: primary
- name: customer_id
type: foreign
- name: customer
expr: customer_id
type: foreign
# Newly added
dimensions:
- name: order_date
Expand Down Expand Up @@ -717,7 +719,8 @@ semantic_models:
entities:
- name: order_id
type: primary
- name: customer_id
- name: customer
expr: customer_id
type: foreign
dimensions:
- name: order_date
Expand Down Expand Up @@ -777,7 +780,8 @@ semantic_models:
entities:
- name: order_id
type: primary
- name: customer_id
- name: customer
expr: customer_id
type: foreign
dimensions:
- name: order_date
Expand Down Expand Up @@ -825,7 +829,7 @@ metrics:
type_params:
measure: order_count
filter: |
{{ Dimension('order_id__order_total_dim') }} >= 20
{{ Metric('order_total', group_by=['order_id']) }} >= 20
# Ratio type metric
- name: "avg_order_value"
label: "avg_order_value"
Expand Down

0 comments on commit 2c0909c

Please sign in to comment.