Make delicious recipes!

Case Statement

CASE has two formats:

Simple CASE Function
CASE price 
  When 1 
    Then 'At Par' 
  When 2
    Then 'Expensive' 
  Else 'Unreasonable'  
Searched CASE Function
  When price == 1 
    Then 'At Par' 
  When price == 2 
    Then 'Expensive'
  Else 'Unreasonable'  

So, the Searched Case syntax is like that of an else if statement in normal programming languages.
While the Simple Case syntax is like that of a switch statement.

Like us on Facebook to remain in touch
with the latest in technology and tutorials!

Got a thought to share or found a
bug in the code?
We'd love to hear from you:

Email: (Your email is not shared with anybody)

Facebook comments:

Site Owner: Sachin Goyal