This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ config( | |
materialized='incremental', | |
as_columnstore=false, | |
pre_hook=""" {% if is_incremental() %} | |
delete from {{this}} | |
where Период >= {{ CurrentDay() }} | |
{% endif %} | |
""" | |
, post_hook = "{% if is_incremental() == false %} | |
{{ create_nonclustered_index( ['Товар']) }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ config( | |
as_columnstore=false | |
, post_hook=[" | |
{{ create_nonclustered_index( ['Товар']) }} | |
{{ create_nonclustered_index( ['СкладКуда']) }} | |
{{ create_nonclustered_index( ['СкладОткуда']) }} | |
"] | |
) | |
}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ config( | |
as_columnstore=false, | |
post_hook=[" | |
{{ create_nonclustered_index( ['Товар']) }} | |
{{ create_nonclustered_index( ['Склад']) }} | |
{{ create_nonclustered_index( ['Период']) }} | |
{{ create_nonclustered_index( ['Регистратор','Товар']) }} | |
"] | |
) | |
}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ config( | |
as_columnstore=false | |
, post_hook=[" | |
{{ create_nonclustered_index( ['Товар']) }} | |
{{ create_nonclustered_index( ['СкладКуда']) }} | |
{{ create_nonclustered_index( ['СкладОткуда']) }} | |
"] | |
) | |
}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select customer_id, | |
redeem_percentage, | |
redeem_amount, | |
cancelled_orders_amount, | |
ordered_basic_goods_qty | |
from clickhouse.cifra.ct_privilege_cards__calculated_indicators | |
WHERE NOT EXISTS | |
(SELECT dbt_statuses."покупатель", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
модель dm | |
{{ config( | |
as_columnstore=false, | |
post_hook=[" | |
{{ create_clustered_index(columns = ['Период']) }} | |
{{ create_nonclustered_index(columns = ['Покупатель']) }} | |
"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select indi.customer_id | |
from clickhouse.cifra.ct_privilege_cards__calculated_indicators as indi | |
WHERE NOT EXISTS | |
(SELECT dbt_statuses."покупатель" | |
from cifratest.dbt_stage."dm_stage_регистрсведений_статусыкартprivilege" as dbt_statuses | |
where indi.customer_id = dbt_statuses."покупатель" | |
and indi.redeem_percentage = dbt_statuses."процентвыкупа" | |
and indi.redeem_amount = dbt_statuses."суммавыкупа" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#single node install config | |
coordinator=true | |
http-server.http.port=8080 | |
#JVM -Xmx20g | |
node-scheduler.include-coordinator=false | |
query.max-memory=32GB | |
discovery.uri=http://localhost:8080 | |
Ошибка |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#single node install config | |
coordinator=true | |
http-server.http.port=8080 | |
#JVM -Xmx20g | |
node-scheduler.include-coordinator=true | |
#query.max-memory-per-node=5GB # jvm*0.25 #Invalid value | |
#memory.heap-headroom-per-node=5GB #jvm*0.2 #Invalid value | |
#query.max-total-memory-per-node=5GB # jvm*0.4 #can not be configured | |
query.max-memory=32GB | |
discovery.uri=http://localhost:8080 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.8' | |
services: | |
dagster-postgres: | |
image: postgres:14.1 | |
container_name: dagster-postgres | |
ports: | |
- 5432:5432 | |
environment: | |
POSTGRES_USER: postgres | |
POSTGRES_PASSWORD: password |
OlderNewer