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!

case statements vs case expressions - Confusion

user12075620Oct 22 2013 — edited Oct 23 2013

Hi,

Could you please someone tell me the difference between the case statements and case expressions?. So far,  I was under impression that both are synonymous. The following lines from

case expressions and statements in oracle 9i

" Most developers seem to use this term when they are in fact describing CASE expressions. The CASE statement is a PL/SQL-only construct that is similar to IF-THEN-ELSE. Its simple and searched formats are as follows."

claims that case statement is only PL/SQL construct. However, Oracle documentation uses both the terms in SQL as well as PL/SQL guide.

Reference:

Case statement in PL/SQL : CASE Statement

Case expressions in PL/SQL :Fundamentals of the PL/SQL Language

I got confused after reading the documentation.

Experts -What's your comments on this?   Thanks for your time.

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 20 2013
Added on Oct 22 2013
19 comments
3,897 views