Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Learn Challenge: Departmental Salary Bands | Advanced CASE WHEN Logic
Mastering CASE WHEN in SQL

bookChallenge: Departmental Salary Bands

Task

Swipe to start coding

Write a query that adds a salary_band column to the employees table result set. The salary_band should be assigned as follows:

  • Assign 'Senior' if salary is greater than or equal to 90000.
  • Assign 'Mid' if salary is between 60000 (inclusive) and 90000 (exclusive).
  • Assign 'Junior' if salary is less than 60000.

Solution

Everything was clear?

How can we improve it?

Thanks for your feedback!

Section 2. Chapter 3
single

single

Ask AI

expand

Ask AI

ChatGPT

Ask anything or try one of the suggested questions to begin our chat

close

bookChallenge: Departmental Salary Bands

Swipe to show menu

Task

Swipe to start coding

Write a query that adds a salary_band column to the employees table result set. The salary_band should be assigned as follows:

  • Assign 'Senior' if salary is greater than or equal to 90000.
  • Assign 'Mid' if salary is between 60000 (inclusive) and 90000 (exclusive).
  • Assign 'Junior' if salary is less than 60000.

Solution

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

Section 2. Chapter 3
single

single

some-alt