hands-on lab

Working With Full-Refresh dbt Models

Beginner
1h
167
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.
Lab 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:

About the author
Students
40,007
Labs
106
Courses
2
Learning paths
10

Stefano studies Computer Science and is passionate about technology. He loves working with Cloud services and learning all the best practices for them. Google Cloud Platform and Amazon Web Services are the cloud providers he prefers. He is a Google Cloud Certified Associate Cloud Engineer. Node.js is the programming language he always uses to code. When he's not involved in studying or working, Stefano loves riding his motorbike and exploring new places.

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