[oracle-db-l] ORA-00913 Too Many Values Error

Question from sravani2k2 on Mar 22 at 1:22 AM
I'm getting error'.(ORA-00913 too many values )' while running below query in database

select the records based on condition

Eg:

select
(

case
when
exists
(
select 1
from hr.employees e,
hr.departments d
where e.department_id=d.department_id
)
then
(
select
e.employee_id,e.first_name,
d.department_name,l.location_id
from hr.employees e,
hr.departments d,
hr.locations l
where e.department_id=d.department_id
and
d.location_id=l.location_id
)
else
(
select
e.manager_id,e.phone_number,
d.department_name,l.location_id
from hr.employees e,
hr.departments d,
hr.locations l
where e.employee_id=d.department_id
and d.location_id=e.location_id
)
end
)

from hr.employees e,
hr.departments d,
hr.locations l


Please resolve the problem.
 
Reply to this email to post your response.
 
__.____._
Manage Settings | Unsubscribe | Create FAQ | Send Feedback
  
Copyright © 2012 Toolbox.com and message author.
Toolbox.com 4343 N. Scottsdale Road Suite 280, Scottsdale, AZ 85251
sravani2k2  
 
View this online
Ask a new question
 
In the Spotlight
Earn Recognition for Your Contributions at Toolbox for IT. Gain Points for Community Achievements

_.____.__

No comments:

Post a Comment