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'  
END
Searched CASE Function
CASE 
  When price == 1 
    Then 'At Par' 
  When price == 2 
    Then 'Expensive'
  Else 'Unreasonable'  
END


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:

Name:
Email: (Your email is not shared with anybody)
Comment:

Facebook comments:

Site Owner: Sachin Goyal