Dropping partitions #2
nuuskamummu
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Planning on implementing functionality to drop old (or simply unwanted) partitions. As you might have noticed, it is a bit clunky to do it manually since the partition needs to be dropped and the corresponding row in the lookup-table needs to be deleted. I have one idea in mind, to add a hidden column to the virtual table, which basically points to the name column in the lookup table. This column could be utilized when using DELETE on the virtual table. E.G. DELETE from "VIRTUAL_TABLE_NAME" where "HIDDEN_COLUMN" = 'partition_name_1' would delete the row from lookup_table and drop the actual partition, as well as refresh the in-memory data to completely remove any references to the deleted data. Furthermore, this could be expanded to automatically remove/archive partitions after a certain time.
Grateful for any feedback. Other ideas or pull requests are more than welcome.
Beta Was this translation helpful? Give feedback.
All reactions