Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Aprende Challenge: Regional Discount Flag | CASE WHEN Basics and Categorization
Practice
Projects
Quizzes & Challenges
Cuestionarios
Challenges
/
Mastering CASE WHEN in SQL

bookChallenge: Regional Discount Flag

Tarea

Swipe to start coding

Write a query that adds a column discount_eligible to the sales table output. The value should be 'Yes' if the region is 'East' or 'West', and 'No' otherwise.

  • Add a column named discount_eligible using a CASE WHEN statement.
  • Return 'Yes' in discount_eligible if the region is 'East' or 'West'.
  • Return 'No' in discount_eligible for all other regions.

Solución

¿Todo estuvo claro?

¿Cómo podemos mejorarlo?

¡Gracias por tus comentarios!

Sección 1. Capítulo 3
single

single

Pregunte a AI

expand

Pregunte a AI

ChatGPT

Pregunte lo que quiera o pruebe una de las preguntas sugeridas para comenzar nuestra charla

close

bookChallenge: Regional Discount Flag

Desliza para mostrar el menú

Tarea

Swipe to start coding

Write a query that adds a column discount_eligible to the sales table output. The value should be 'Yes' if the region is 'East' or 'West', and 'No' otherwise.

  • Add a column named discount_eligible using a CASE WHEN statement.
  • Return 'Yes' in discount_eligible if the region is 'East' or 'West'.
  • Return 'No' in discount_eligible for all other regions.

Solución

Switch to desktopCambia al escritorio para practicar en el mundo realContinúe desde donde se encuentra utilizando una de las siguientes opciones
¿Todo estuvo claro?

¿Cómo podemos mejorarlo?

¡Gracias por tus comentarios!

Sección 1. Capítulo 3
single

single

some-alt