Get Example source ABAP code based on a different SAP table
ABAP_CDS_DDL - DDIC-Based View, simple_case_expr>
ABAP_SYNTAX ... CASE operand WHEN operand1 THEN result1 $[WHEN operand2 THEN result2$] ... $[ELSE resultn$] END ...>
What does it do? Simple case distinction> (simple case>) in a SELECT> statement > of a ABAP_CDS_V1_VIEW >. The case distinction compares the values of operand operand> with operands operand1 >, operand2>, ... and produces the operand result> as the result after the first THEN> for which the comparison is true. If no matches are found, the result> specified after ELSE> is selected. If ELSE> is not specified, the result is the null value>.