Quote (Ironfister @ Sep 28 2013 04:24pm)
CASE
WHEN manager_id is null THEN 'none'
ELSE manager_ID
end
edit:
nvl should also work and this is probably prefered way to solve this problem.
Yeah this is odd becaues:
Code
SELECT department_id, department_name, manager_id, location_id
CASE manager_id
WHEN manager_id = NULL THEN 'none'
ELSE manager_id
END
FROM departments;
I still get error with this current code?
"ORA-00923: FROM keyword not found where expected
00923. 00000 - "FROM keyword not found where expected"
It says the error is where the 'm' is after the CASE -- That is where it is saying it is located. But i double checked the table column names etc, and it is pointing to the correct column?