Parameters: (String, String, String,String);
Returns: String;
Function to map an input with the key and return the value, given a list of key-value pairs.
The first parameter is the input value.
The second parameter is the default value.
The third parameter is the key.
The fourth parameter is the value to return from the key-value pairs, where the input matches with the key.
If the input matches the key, the value associated with the key will be returned.
If the input does not match with any of the keys, the default value will be returned(can be NULL).
Can have more than one set of key-value pairs, but, should have minimum 4 parameters.
Example:
CASE('Greenwich Mean Time','America/Los_Angeles','Greenwich Mean Time','GMT')= 'GMT'
CASE('Purchasing','IT','Human Resources','HR','Marketing &Sales','Sales','Information Technology','IT','Accounting & Finance','Finance')='IT'
Comments
0 comments
Please sign in to leave a comment.