1. Learn
  2. /
  3. Courses
  4. /
  5. Introduction to BigQuery

Connected

Exercise

Using multiple CTEs

Using multiple CTEs can greatly improve the performance and legibility of code. In this example, you will split a query into two CTEs to make it easier to read and more performant.

Instructions 1/2

undefined XP
    1
    2
  • Create a new CTE named orders that will extract the order_id column along with the product_id and price from the nested order_items column, all from the ecommerce.ecomm_orders table.
  • Filter for price greater than 100.