-
Notifications
You must be signed in to change notification settings - Fork 358
Open
Labels
FeatureAdds new functionalityAdds new functionalityUXIssues related to user experience such as config setting, cli output, debuggingIssues related to user experience such as config setting, cli output, debugging
Description
Let's make it easy to add model defaults to different subfolders within a sqlmesh project. We have it at the project level and individual model level, but nothing in between. This will be helpful for granting permissions, grouping together pre/post-statements, etc.
Similar to this recent PR: #4995
Model config override behavior: model > subfolder > project
Quick and dirty mockup for config.yaml:
model_defaults:
dialect: duckdb
pre_statements:
- "SET timeout = 300000"
post_statements:
- "@IF(@runtime_stage = 'evaluating', ANALYZE @this_model)"
on_virtual_update:
- "GRANT SELECT ON @this_model TO ROLE analyst_role"
subfolder_a:
dialect: snowflake
pre_statements:
- "SET timeout = 200000"
subfolder_b:
pre_statements:
- "SET timeout = 400000"Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
FeatureAdds new functionalityAdds new functionalityUXIssues related to user experience such as config setting, cli output, debuggingIssues related to user experience such as config setting, cli output, debugging