Data Quality Checks with dbt-expectations
📖 Scenario: You work as a data analyst in a retail company. You want to make sure the sales data you use is clean and reliable before making reports. Using dbt-expectations, you will add simple data quality tests to your sales data model.
🎯 Goal: Build a dbt model for sales data and add dbt-expectations tests to check for missing values and valid ranges. Finally, run the tests and see the results.
📋 What You'll Learn
Create a dbt model file with sample sales data
Configure the model to materialize as a table
Write dbt-expectations tests to check for nulls and valid sales amounts
Run the tests and print the test results
💡 Why This Matters
🌍 Real World
Data analysts and engineers use dbt-expectations to automate data quality checks and catch errors early in data pipelines.
💼 Career
Knowing how to write and run data quality tests with dbt-expectations is a valuable skill for data engineers and analytics engineers.
Progress0 / 4 steps