GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - andreamorasal/sales-analytics-dbt-airflow-pipeline: End-to-end data pipeline transforming raw Snowflake coffee sales data into analytics-ready datasets using dbt and Airflow in Docker.

BranchesTags
Open more actions menu

Latest commit

 

History

4 Commits
4 Commits

Folders and files

NameName
Last commit message
Last commit date
airflow
airflow
 
 
data
data
 
 
sales_analytics
sales_analytics
 
 
screenshots
screenshots
 
 
sql
sql
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
docker-compose.yml
docker-compose.yml
 
 

Repository files navigation

Coffee Sales Analytics Pipeline ☕

An end-to-end data engineering project that transforms raw coffee sales data in Snowflake into analytics-ready datasets using dbt, with Apache Airflow orchestrating the workflow in Docker.

Project overview

This project demonstrates an ELT pipeline built around a coffee sales dataset containing 3,636 transactions.

Raw sales data is stored in Snowflake, transformed using dbt, and organised into staging and analytical models. Apache Airflow orchestrates the workflow, including connection validation, model execution and data quality testing.

Architecture and workflow

The pipeline integrates three main components:

  • Snowflake: Stores the raw coffee sales data and the resulting analytical models.
  • dbt: Performs SQL transformations, develops staging and mart models, and runs data quality tests.
  • Apache Airflow: Orchestrates the pipeline, manages task dependencies and executes the dbt workflow.

The environment is containerised using Docker and Docker Compose.

Data models

Staging

stg_coffee_sales

Standardises the raw transaction data by renaming columns and preparing the data for analytical transformations.

Marts

mart_daily_coffee_sales

Aggregates sales data by date, including:

  • Total transactions
  • Distinct coffee types
  • Total revenue
  • Average transaction value

mart_coffee_product_performance

Aggregates sales performance by coffee product, including:

  • Total transactions
  • Total revenue
  • Average selling price

Data quality

dbt tests validate the transformed data, including:

  • Not-null checks
  • Unique key checks
  • Data completeness

The pipeline runs 16 dbt tests as part of its validation workflow.

Screenshots

Airflow orchestration

Airflow DAG success

dbt data quality tests

Airflow dbt test results

Snowflake analytical models

Snowflake analytics models

dbt model lineage

dbt lineage

Snowflake query history

Snowflake query history

Technologies

  • Snowflake
  • dbt
  • Apache Airflow
  • Docker and Docker Compose
  • SQL and Python
  • Git and GitHub

Key learnings

  • Building an ELT pipeline using a cloud data warehouse.
  • Developing modular SQL transformations with dbt.
  • Implementing data quality checks.
  • Orchestrating dependent tasks with Apache Airflow.
  • Containerising and managing an Airflow environment with Docker.
  • Integrating Snowflake, dbt and Airflow into one workflow.

About

End-to-end data pipeline transforming raw Snowflake coffee sales data into analytics-ready datasets using dbt and Airflow in Docker.

Topics

airflowairflow-dagairflow-dagsairflow-dockerairflow-operatorairflow-tasksdata-lineage-graph-dbdbtdockerdocker-composedocker-containerdockerfiledockerfilespythonsales-analyticssales-automationsnowflakesnowflake-sqlsqlvisual-code

Resources

Readme
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.