pipelinedb
pipelinedb copied to clipboard
Add support for renaming continuous views/transforms
Hi, If I want to change the name of continuous view, how to do it? Thanks!
Hi @qcli,
Currently there isn't a great way to rename a continuous view. Here's how you could do it though:
-
CREATEthe new CV (identically to the existing one, of course) - Copy all data from the old CV's materialization table (
<cv name>_mrel) into the new one:
-- Enable user-level writes on materialization tables for this transaction
SET continuous_query_materialization_table_updatable TO on;
-- Now just copy the old materialization table's rows into the new one
INSERT INTO <new cv name>_mrel SELECT * FROM <old cv name>_mrel;
- Once you've verified that the new CV looks good,
DROPthe old CV
I realize this isn't ideal but I just wanted to offer a workaround approach until we support renaming, which we eventually will.
Hi @derekjn , Thank your reply. Looking forward to the day you support this feature.