forked from get-select/dbt-snowflake-monitoring
-
Notifications
You must be signed in to change notification settings - Fork 0
Enable package to use Snowflake Organisation Account views #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
bisset-a
wants to merge
32
commits into
main
Choose a base branch
from
annab-support-org-views
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
32 commits
Select commit
Hold shift + click to select a range
5a9028b
update models
bisset-a 1c2e124
resolving merge conflicts
bisset-a e1aa209
fix
bisset-a 9f3ae59
fix
bisset-a 9441a6b
fix
bisset-a b454928
create org level hourly_spend model
bisset-a c622d6f
remove account_name col from stg_remaining_balance_daily
bisset-a f575b39
remove account_name col from stg_remaining_balance_daily downstreams
bisset-a eec7af9
fix
bisset-a 665d6b2
fix for daily_rates
bisset-a 05986b9
removing invalid columns from hourly_spend_org_level
bisset-a f6596b1
adding account_name to hourly_spend_org_level
bisset-a da2a75b
adding aliases in hourly_spend_org_level
bisset-a 2d5b055
syntax fix hourly_spend_org_level
bisset-a 940683f
adding account_locator it unique key of incremental models
bisset-a b48479a
update cost_per_query to support org views
bisset-a 920a041
syntax fix cost_per_query
bisset-a b89364e
typo
bisset-a fdd0501
create org level daily_spend model
bisset-a ee96481
dynamic unique key cost_per_query
bisset-a f0a7fff
dynamic unique key stg_warehouse_metering_history
bisset-a bf5679c
fix columns cost_per_query
bisset-a b53faa9
change daily_rates to use account_locator instead of account_name
bisset-a cb5585c
remove invalid cols
bisset-a 5576c07
dynamic unique key incrementals
bisset-a f76aca5
add account_locator to daily_rates partition
bisset-a 2cd82b7
replace org columns and unique key with macros
bisset-a a2b34c0
removing unique key macro
bisset-a 701fe29
adding comments to conditionally disabled models
bisset-a 29d325e
Merge branch 'main' into annab-support-org-views
bisset-a 62cb54b
adding comments to conditionally disabled models
bisset-a 2add855
remove redundant filter cost_per_query
bisset-a File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{% macro add_account_columns() %} | ||
{% if var('uses_org_view', false) %} | ||
organization_name, | ||
account_name, | ||
account_locator, | ||
{% else %} | ||
current_organization_name() as organization_name, | ||
current_account_name() as account_name, | ||
current_account() as account_locator, | ||
{% endif %} | ||
{% endmacro %} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's add a comment just to show that we can do this once
metering_history
is available at org level?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done!