Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

SELECT INTO Returning 1 row

448221Mar 30 2006 — edited Mar 30 2006
Usually if I have a SELECT INTO, I would catch the NO_DATA_FOUND/ TOO_MANY_ROWS exceptions to ensure there is only 1 row returned. However, from my java experience, catching exception as a way to handle normal processing logic is not a good programming practice. Is it also true for PLSQL?

If yes, how should we change our code without using exception. I can handle too_many_rows by adding the ROWNUM=1 condition to my SELECT. But how about NO_DATA_FOUND?

Thx
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 27 2006
Added on Mar 30 2006
9 comments
573 views