¿Cómo adaptarías esta consulta para limitar los resultados solo a la segmentación por palabras clave de Sponsored Products? SELECT ad_product_type, targeting, customer_search_term, match_type, SUM(spend)/100000000 AS total_cost_dollars,((SUM(spend)/100000000)/SUM(impressions))*1000 AS avg_cpm, SUM(impressions) AS impressions, SUM(clicks) AS clicks, (SUM(clicks)/SUM(impressions)) AS ctr FROM sponsored_ads_traffic WHERE match_type IN('PHRASE', 'BROAD', 'EXACT') GROUP BY 1,2,3,4
Elige una respuesta
Toca una opción para verificar tu respuesta.
Respuesta correcta: Ajustar la instrucción WHERE a: WHERE match_type IN('PHRASE', 'BROAD', 'EXACT') AND ad_product_type = 'sponsored_products'.
Por qué esta es la respuesta
The correct answer filters the results to include only 'sponsoredproducts' by adding AND adproducttype = 'sponsoredproducts' to the WHERE clause. This directly targets the desired ad product type. The other options are incorrect because: Adding LIMIT sponsoredproducts is syntactically incorrect for SQL and does not filter by product type. LIMIT is used to restrict the number of rows returned. Adjusting the FROM instruction to FROM sponsoredproducts would change the table being queried, which is not the intent; the query is already using sponsoredadstraffic. Adjusting the SELECT instruction to include sponsoredproducts would attempt to select a field that likely doesn't exist or isn't relevant for filtering, and it wouldn't filter the rows.
Aprueba tu examen — sin la interminable búsqueda de respuestas
Obtén todas las preguntas y explicaciones verificadas para este examen en un solo lugar, y ahorra horas de preparación. Más de 1,000 certificaciones · Más de 20 idiomas · Empieza gratis.
Aprueba tu examen más rápido → No se requiere tarjeta