Skip to content

Setting incremental does not take effect #97

@JinLin6564

Description

@JinLin6564

version:
dbt core =1.3.3
dbt hive =1.3.1
python =anaconda3/python3.9

I set config and 'is_ Incremental 'is in SQL but does not take effect. After the second execution, it will be prompted that the same table already exists in hive. I checked the SQL and found that converting to 'create table as' is not an insert syntax

test_1.sql:
{{
config(
materialized='incremental'
)
}}

select * from {{ ref('test') }}

{% if is_incremental() %}

where event_time = (select max(event_time) from {{ this }} )

{% endif %}

error:Hive server: Error while compiling statement: FAILED: SemanticException org.apache.hadoop.hive.ql.parse.SemanticException: Table already exists: testdb.test_1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions