Valued CASE Expression Syntax | Teradata Vantage - 17.10 - Valued CASE Expression Syntax - Advanced SQL Engine - Teradata Database

Teradata Vantageā„¢ - SQL Functions, Expressions, and Predicates

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Programming Reference
Publication ID
B035-1145-171K
Language
English (United States)
CASE value_expression_1 when_clause [...] [ ELSE scalar_expression_m ] END

Syntax Elements

value_expression_1
An expression whose value is tested for equality with value_expression_n.
when_clause
WHEN value_expression_n THEN scalar_expression_n
scalar_expression_m
An expression whose value is returned if evaluation falls through to the ELSE clause.
value_expression_n
A set of expressions against which the value for value_expression_1 is tested for equality.
scalar_expression_n
An expression whose value is returned on the first equality comparison of value_expression_1 and value_expression_n.