gpt4 book ai didi

sql - DBT 完全刷新会删除我所有的物化 View 。 Postgres

转载 作者:行者123 更新时间:2023-12-03 08:44:53 25 4
gpt4 key购买 nike

我们正在使用 DBT 来管理我们的数据管道。我们还使用 postgres 作为我们的数据库。我正在通过查询(不在 dbt 中)创建一些物化 View ,看起来每当我们运行 dbt run --full-refresh 时,它都会删除这些物化 View 。知道为什么以及如何不删除物化 View 吗?

最佳答案

这个答案来自 DBT 的 Claire。

“如果物化 View 依赖于上游表,它们将被 drop table my_table 级联语句删除”

这来自 DBT 的 Jake。“postgres View /物化 View 具有约束力。没有选择退出,即使在同一个 dbt 运行中重新创建它们也会导致它不可用。”

https://www.postgresql.org/docs/9.3/rules-materializedviews.html https://docs.getdbt.com/

关于sql - DBT 完全刷新会删除我所有的物化 View 。 Postgres,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/61900980/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com