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!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Returning a default value in SQL when no rows found

cubmarJun 13 2008 — edited Oct 4 2013
Hi

How can change my SQL to return a default value if no rows are found?

Eg:
select text from text_file where criteria=met

If no rows are found, I would like text to contain '**Empty' for example


Thanks

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Nov 1 2013
Added on Jun 13 2008
19 comments
146,034 views