The CASE expression is used to implement the logic where you want to set the value of one column depending upon the values in other columns.
The SQL Server CASE expression consists of at least one pair of WHEN and THEN expressions. The WHEN expression specifies the condition to be tested. The THEN expression specifies the action if the WHEN condition returns TRUE.
The ELSE expression is optional and executes when none of the WHEN conditions return true. The CASE expression ends with an END keyword.
Simple CASE expression:
CASE input_expression
WHEN when_expression THEN result_expression [ ...n ]
[ ELSE else_result_expression ]
END
Searched CASE expression:
CASE
WHEN Boolean_expression THEN result_expression [ ...n ]
[ ELSE else_result_expression ]
END
Auf dieser Seite können Sie das Online-Video CASE EXPRESSION | SQL Server | SQL Tutorial mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Uday Bhoyar 04 Dezember 2022 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 154 Mal angesehen und es wurde von 8 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!