Employees earning more than their manager
Ozon's HR analytics team flags compensation anomalies — cases where a direct report earns more than their manager. Used for performance review and grade calibration. The table has an is_active flag to exclude terminated staff.
Find all active employees (is_active = TRUE) whose salary is higher than their active manager's salary, and show the report's salary alongside the manager's.
Expected output sample
This is what a correct answer looks like — its row count is its own, it doesn't have to match the schema tables.
| salary | employee_id | manager_salary |
|---|---|---|
| 270000.00 | 3 | 250000.00 |
| 200000.00 | 5 | 180000.00 |
| 285000.00 | 7 | 270000.00 |
Ozon
Sign in to see submission history
Sign inSign in to use AI Mentor
Sign inFocus radio
Paused · SomaFM · Fluid