dbt

macros are not recognised in dbt

macros are not recognised in dbt Question: {{ config ( pre_hook = before_begin("{{audit_tbl_insert(1,’stg_news_sentiment_analysis_incr’) }}"), post_hook = after_commit("{{audit_tbl_update(1,’stg_news_sentiment_analysis_incr’,’dbt_development’,’news_sentiment_analysis’) }}") ) }} select rd.news_id ,rd.title, rd.description, ns.sentiment from live_crawler_output_rss.rss_data rd left join live_crawler_output_rss.news_sentiment ns on rd.news_id = ns.data_id limit 10000; This is my model in DBT which is configured with pre and post hooks which referance a …

Total answers: 2

Uninstalling python is not unistalling the 'dbt' package

Uninstalling python is not unistalling the 'dbt' package Question: "dbt" package was installed using the command pip install dbt-snowflake dbt commands were used successfully (dbt debug , dbt run etc.) After that python was completely uninstalled and installed again. The dbt commands are successfully running without installing them again using pip. Is it possible that …

Total answers: 1

DBT – How to insert data twice in the same table using DBT?

DBT – How to insert data twice in the same table using DBT? Question: I have the scenario, where I need to insert into the same table but in two steps First, I insert parent rows & hence get the Auto Incremented IDs from the database Second, I need to insert child data, which will …

Total answers: 1

How to implement Python UDF in dbt

How to implement Python UDF in dbt Question: Please I need some help with applying python UDF to run on my dbt models. I successfully created a python function in snowflake (DWH) and ran it against a table. This seems to work as expected, but implementing this on dbt seems to be a struggle. Some …

Total answers: 2

pass a macro as a parameter jinja dbt

pass a macro as a parameter jinja dbt Question: {{ today_date_milliseconds() }} – is my macro in the project. How to redirect this macro as a parameter, so it will be by default and I could in yml write another macro? {% test valid_date(model, column_name, exclude_condition = ‘1=1’) %} SELECT {{ column_name }} FROM {{ …

Total answers: 1