Following the Analytics Engineering Bootcamp on Udemy by Rahul Prasad and David Badovinac, but using the PostgreSQL database on localhost.
git clone https://github.com/maprihoda/analytics_engineering_bootcamp_postgres.git
cd analytics_engineering_bootcamp_postgres
psql postgres
CREATE DATABASE analytics_engineering_bootcamp_postgres;
exit
psql -U your_username -d analytics_engineering_bootcamp_postgres
CREATE SCHEMA dl_northwind;
SET search_path TO dl_northwind;
\i northwind.sql
exit
Create the virtual environment with pyenv:
pyenv virtualenv 3.10.10 analytics_engineering_bootcamp_postgres
pip install dbt-postgres
cp profiles-example.yml ~/.dbt/profiles.yml
open ~/.dbt/profiles.yml
After opening the ~/.dbt/profiles.yml file, update it by filling in your database username and password.
Verify that the setup is complete:
dbt debug
dbt run
- Learn more about dbt in the docs
- Check out Discourse for commonly asked questions and answers
- Join the chat on Slack for live discussions and support
- Find dbt events near you
- Check out the blog for the latest news on dbt's development and best practices