-
Notifications
You must be signed in to change notification settings - Fork 59
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
[Feature] Add TRUNCATE INSERT to materializations list #879
Comments
@akmalsoliev Does the |
@amychen1776 Hello and sorry for a late reply. Using DELETE + INSERT is not ideal because it occasionally changes the predefined data type. For example, a VARCHAR(100) might unexpectedly become VARCHAR(250). This is not the desired behaviour; we want the operation to forcefully fail in such cases. I understand that this should not be happening, however, in practice this action occurred. |
Thank you for the clarification! That is odd that it would change the data type. |
I don't mind making a PR, if you're open for a contribution |
A contribution will always be welcomed :) |
Hey @amychen1776 any tips and tricks on where to get started with this issue? I took a look around and it appears that most of the materialisation macros are located in |
@akmalsoliev as a side note - I'm curious if this would help resolve your use case? dbt-labs/dbt-core#10672 |
Is this your first time submitting a feature request?
Describe the feature
Instead of creating a new table, the approach involves using a TRUNCATE operation followed by an INSERT to update the existing materialized tables, which already have predefined data types.
Describe alternatives you've considered
No response
Who will this benefit?
This feature benefits database administrators, data engineers, developers, business analysts, and organizations by efficiently updating large datasets in existing materialized tables without the need for creating new tables, ensuring data integrity and speeding up data refreshes and decision-making processes.
Are you interested in contributing this feature?
Yes
Anything else?
No response
The text was updated successfully, but these errors were encountered: