hi,
Sir in my project there is a table emp_info have three field employee name, address and salary.
and i want to show record like that if employee salary > 25000 show manager, salary>15000 and <=25000 are supervisor and salary<=15000 are trainee.
how can we get this record advised me a proper query ?
Loading

SenthilkumarPosted Apr 11, 2012, 12:04 AM
Utpal PatelPosted Apr 10, 2012, 12:56 PM
SELECT Emp_Name, Emp_Address, Emp_Salary ,
CASE
WHEN Emp_Salary > 25000 THEN 'Manager'
WHEN Emp_Salary > 15000 AND Emp_Salary <=25000 THEN 'Supervisor'
ELSE 'Trainee'
END AS Designation
From Employee_M