select employees.emp_no, employees.birth_date, employees.first_name, employees.last_name,
case
when dept_manager.emp_no IS NOT NULL THEN 'Manager' ELSE 'Employee' END AS Is_Manager
from employees
WHEN employees.gender = 'M' THEN 'Male' ELSE 'Female' END AS 'Gender'
LEFT JOIN
dept_manager ON dept_manager.emp_no = employees.emp_no;
I wanted to get employees with their gender and whether manager or not. I thought I could use CASE with two conditions. On introducing the second condition I got an EOF error. Kindly help check what could be wrong with my code.