- Docker - https://docs.docker.com/desktop/install/mac-install/
- VSCode
- VSCode extension: Dev Containers
This gist will contain two options - dbt Core or dbt Cloud CLI The following steps are required by both:
| CREATE OR REPLACE PROCEDURE ANALYTICS.dbt_markwan_sprocs.CalculateMonthlySalesByNation() | |
| RETURNS VARCHAR | |
| LANGUAGE SQL | |
| AS | |
| $$ | |
| BEGIN | |
| -- Create the temporary table for months | |
| CREATE OR REPLACE TEMPORARY TABLE temp_months AS ( | |
| WITH RECURSIVE cte_months AS ( |
This gist will contain two options - dbt Core or dbt Cloud CLI The following steps are required by both:
| {{ | |
| config( | |
| materialized='table' | |
| ) | |
| }} | |
| with | |
| source as ( |
| {{ | |
| config( | |
| materialized='view' | |
| ) | |
| }} | |
| with final as ( | |
| select | |
| store_id || "-" || cast(id as string) as unique_id, | |
| pk, |