Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I wrote in PL/SQL Developer:

select * from lc_history2

and I got that error:

ORA-01427: single-row subquery returns more than one row

Can someone help? It's necessary.

share|improve this question
add comment

1 Answer

Without further information, I can only guess that lc_history2 is a view that somehow looks like

 select 
   c,o,l,u,m,n,s
 from
   table where
     some_column = (select another_column 
              from table
             where something = 'SOMEVALUE')

and the inner select returns more than one record for something = 'SOMEVALUE'

share|improve this answer
    
so what do i suppose to do? –  esh Feb 13 '12 at 12:36
    
Verify if this is the case and if so, adjust the view according to what you want it to return. Maybe, it's sufficient to change the = into a in, but then again, maybe, it's not. –  René Nyffenegger Feb 13 '12 at 12:42
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.