Code Monkey home page Code Monkey logo

Comments (2)

chenzl25 avatar chenzl25 commented on June 2, 2024

Different from other OLAP databases or data warehouses, they use dbt to do ELT. RisingWave is a streaming database, that can maintain a streaming pipeline incrementally in real-time, so you just need to run dbt run once unless you modify your models. That is the difference between an OLAP database and a streaming database.

from dbt-risingwave.

neverchanje avatar neverchanje commented on June 2, 2024

I agree with the idea that RisingWave should not recreate materialized views and tables on each dbt run, unless the user specify '--full-refresh' or '-f'. https://docs.getdbt.com/reference/commands/run

Here is the prototype code that we can express it.

  {%- set old_relation = adapter.get_relation(database=database, schema=schema, identifier=identifier) -%}
  {%- set exists_as_materialized_view = (old_relation is not none and old_relation.is_materialized_view) -%}

  {%- if exists_as_materialized_view or should_full_refresh() -%}
    -- If there's a table with the same name and we were told to full refresh, drop it.
    -- build model
    {% call statement('main') -%}
      {{ get_create_materialized_view_as_sql(target_relation, sql) }}
    {%- endcall %}
  {%- endif -%}

from dbt-risingwave.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.