hands-on lab

Working With Full-Refresh dbt Models

Difficulty: Beginner
Duration: Up to 1 hour
Students: 191
Rating: 4.5/5
Get guided in a real environmentPractice with a step-by-step scenario in a real, provisioned environment.
Learn and validateUse validations to check your solutions every step of the way.
See resultsTrack your knowledge and monitor your progress.

Description

When you need to define new models, everyone has different behavior and data exposed. There are models containing data that represent events and records that can't change once they are created (ex. A model that contains bank transactions records), but there are also models that could contain records that can change  (ex. A model that contains information about a user).

Because of that, dbt allows you to leverage different types of materialization for your dbt models. By using the table materialization type, you define full-refresh models. It means that every time a dbt execution is performed, the table is created if not exist, or truncated, and then populated again. So, all the records are fresh.

In this lab, you will create two dbt models using the table materialization type, and you will check that on each execution the table is truncated and then populated again with fresh records.

Learning Objectives

Upon completion of this lab, you will be able to:

  • Understand what are full-refresh models
  • Work and create full-refresh dbt models 

Intended Audience

  • Data engineers with a focus on data modeling and transformations methodologies
  • Developers that need to understand different kinds of dbt materialization techniques

Prerequisites

To get the most from this lab, you should have basic knowledge of dbt. To get ready, you can use the following labs:

Covered topics

Lab steps

Understanding Full-Refresh dbt Models
Connecting to the dbt Web IDE
Creating dbt Models Using Table Materialization
Executing Full-Refresh dbt Models