Dataford
Interview QuestionsInterview GuidesExperiencesMock InterviewsPricing
Get started
Highest Salary and Ranking
00:00
5 left

Highest Salary and Ranking

EasySQL · PostgreSQL

Problem

Meesho's People Analytics team needs a quick view of the maximum salary currently recorded in its employee dataset. Write a PostgreSQL query that returns the highest salary value from the employees table.

Requirements

  1. Return one row containing the highest non-NULL salary.
  2. Name the result column highest_salary.

Schema

employees
ColumnTypeDescription
employee_idPKINTEGERUnique employee identifier
employee_nameVARCHAR(100)Employee's full name
departmentVARCHAR(50)Employee's department
salaryNUMERIC(12,2)Annual salary in Indian rupees
Tablesemployees
Interviewer

Your question is Highest Salary and Ranking. Start with the requirements and the one table in the Question tab.

Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.

You need to log in / sign up to run or submit.
CodePostgreSQL
You need to log in / sign up to run or submit.Ln 1
Run your query to see results here.