GithubHelp home page GithubHelp logo

dbt-snowflake-project-digitalskola's Introduction

Integration Batch Projection with DBT-Snowflake Project 4 Digital Skola

Project Brief

The project aimed to gain my skills of Data Engineering regarding Best Practice of Pipeline using DBT and Snowflake. DBT is a tool to build useful documentation of Data Pipeline process start with Data Raw Collection, Data Transforming and Data Mart.

Success Criteria

  • Instantiate dbt project directory namely digitalskola_climate
  • Connect to Snowflake
  • Classify models : stagging, intermediate, mart in digitalskola_climate/dbt_project.yml
  • Configure schema.yml and sources.yml
  • Run and learn behaviours of dbt run -s <model>, dbt build, dbt test, dbt deps
  • Generate documentation and run the UI
  • Implement best practice using macros dbt_utils like star macros

How to DBT Init

  1. Create python virtual environment python3 -m venv env
  2. Install the requirements.txt python3 -m pip install -r requirements.txt
  3. Initialize DBT project dbt init. Identifier account should be : <orgname>-<account_name>
  4. Choose keypair auth for more secure way to authenticate
  5. Generate key pair and setup public key for specific user in Snowflake https://docs.snowflake.com/en/user-guide/key-pair-auth
  6. Run your first model dbt run -s my_first_dbt_model
  7. If database not found don't forget to create it first using CREATE DATABASE <DB_NAME>;
  8. Setup profiles.yml https://docs.getdbt.com/docs/core/connect-data-platform/snowflake-setup
  9. Setup sources https://docs.getdbt.com/docs/build/sources

Hardening profiles.yml

  1. Open the profiles.yml
  2. For the confidentials params/keys replace the value with "{{ env_var('VAR_NAME') }}"
  3. Run Command EXPORT VAR_NAME=<confidential_value>

dbt-snowflake-project-digitalskola's People

Contributors

artso17 avatar ayyoubmaul avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.