Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Impara Challenge: BigQuery Data Selection | Query Engine Basics
Practice
Projects
Quizzes & Challenges
Quiz
Challenges
/
BigQuery Fundamentals

bookChallenge: BigQuery Data Selection

Scorri per mostrare il menu

Note
Modern Practice

In the video and course examples, you will see the JSON_EXTRACT function. While this function is fully supported and works correctly, it is considered legacy syntax in BigQuery.

For your own future projects, we recommend using the modern standard functions:

  • JSON_VALUE: extracts scalar values (like strings or numbers) and removes extra quotes automatically;
  • JSON_QUERY: extracts complex JSON objects or arrays.

Your task is to analyze customer shopping patterns while demonstrating your understanding of BigQuery's specialized features.

  1. Write a query that uses partition pruning by filtering on the appropriate partition column (_PARTITIONDATE);
  2. Use APPROX_COUNT_DISTINCT to efficiently count unique customers;
  3. Include at least one JSON extraction from the products field;
  4. Group your results in a meaningful way.
Note
Note

To use _PARTITIONDATE for partition pruning, ensure the BigQuery table is created with Partition by: Ingestion time. Without this setting, the pseudo-column will not exist, and the query will fail.

Tutto è chiaro?

Come possiamo migliorarlo?

Grazie per i tuoi commenti!

Sezione 2. Capitolo 4

Chieda ad AI

expand

Chieda ad AI

ChatGPT

Chieda pure quello che desidera o provi una delle domande suggerite per iniziare la nostra conversazione

Sezione 2. Capitolo 4
some-alt