dbt-labs / dbt-labs/dbt-adapters
[Feature] Snowflake adapter: remove unnecessary automatic clustering from table materializations
- Dominant language
- Python
- Stars
- 233
- Forks
- 362
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 9
Description
### Is this your first time submitting a feature request?
- [x] I have read the [expectations for open source contributors](https://docs.getdbt.com/docs/contributing/oss-expectations)
- [x] I have searched the existing issues, and I could not find an existing issue for this feature
- [x] I am requesting a straightforward extension of existing dbt functionality, rather than a Big Idea better suited to a discussion
### Describe the feature
Currently, `cluster_by` can be applied to `table` materializations. This has the effect of both ordering by the clustering key **and** enabling automatic clustering. For tables, however, the data is always ordered by the key; enabling the automatic clustering will redundantly burn some small, fractional amount of credits to determine that the table is perfectly clustered.
I believe that it would be more ergonomic if `cluster_by` only added ordering to tables. There could be an additional flag to enable automatic clustering for tables if someone is doing something exotic like running `update`s via stored procs that could impact the ordering of the table.
### Describe alternatives you've considered
Users could just not use `cluster_by` in tables and add `ORDER BY` at the end of their models. This, however, is an inconsistent experience with incremental materializations.
### Who will this benefit?
This could benefit most Snowflake users working with tables that require ordering for performance purposes.
### Are you interested in contributing this feature?
_No response_
### Anything else?
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.