Skip to content

Preview CTEs (Common Table Expressions)

dbt Power User allows you to preview individual CTEs (Common Table Expressions) within your dbt models, making it easier to debug and understand complex queries by examining each component separately.

What are CTEs?

Common Table Expressions (CTEs) are temporary named result sets that exist within the execution scope of a single SQL statement. They help break down complex queries into more manageable, readable pieces. In dbt, CTEs are often used to organize complex transformations into logical steps.

Preview Individual CTEs

Using the CTE Preview Feature

You can preview the results of individual CTEs within your dbt model:

  1. Open your dbt model in the editor
  2. Locate the CTE you want to preview
  3. Click on Execute CTE right above the CTE