ComenzarEmpieza gratis

Finding order total value

A common use case for BigQuery is creating analytical reports, such as finding the top 10 results from a query or results within a certain timespan.

For this query, you will find the 10 smallest orders by total cost using the ecommerce.ecomm_payments.

Este ejercicio forma parte del curso

Introduction to BigQuery

Ver curso

Instrucciones del ejercicio

  • Select the ten smallest orders from the ecommerce.ecomm_payments using SUM on the payment_value column for the first 10 rows of data.

Ejercicio interactivo práctico

Prueba este ejercicio y completa el código de muestra.

-- Add the correct column and limit values

SELECT
	-- Add the column to calculate the SUM
	order_id, SUM(___)
FROM 
    ecommerce.ecomm_payments
GROUP BY order_id
-- Add the correct column to order
ORDER BY ___
-- Add the correct number of rows to limit
LIMIT ___;
Editar y ejecutar código