Yahoo Poland Wyszukiwanie w Internecie

Search results

  1. 3 wrz 2024 · Imposes conditions on the execution of a Transact-SQL statement. The Transact-SQL statement that follows an IF keyword and its condition is executed if the condition is satisfied: the Boolean expression returns TRUE .

  2. 15 wrz 2008 · The CASE statement is the closest to IF in SQL and is supported on all versions of SQL Server. SELECT CAST ( CASE WHEN Obsolete = 'N' or InStock = 'Y' THEN 1 ELSE 0 END AS bit) as Saleable, * FROM Product. You only need to use the CAST operator if you want the result as a Boolean value.

  3. 21 maj 2024 · Imposes conditions on the execution of a Transact-SQL statement. The Transact-SQL statement (sql_statement) following the boolean_expression is executed if the boolean_expression evaluates to TRUE. The optional ELSE keyword is an alternate Transact-SQL statement that is executed when boolean_expression evaluates to FALSE or NULL.

  4. 30 lis 2019 · Transact-SQL IF THEN ELSE to typowa instrukcja warunkowa. Wykonuje blok kodu, jeśli warunek ujęty przed blokiem jest spełniony. Jeśli nie jest spełniony mamy do dyspozycji opcjonalny warunek ELSE. Instrukcję IF THEN ELSE w SQL Server możemy używać w T-SQL m. in. w blokach anonimowych, procedurach, funkcjach, triggerach.

  5. The IF...ELSE statement is a control-flow statement that allows you to execute or skip a statement block based on a specified condition. The IF statement. The following illustrates the syntax of the IF statement: IF boolean_expression . BEGIN . { statement_block } END Code language: SQL (Structured Query Language) (sql)

  6. 12 wrz 2022 · The IF statement in T-SQL works very much like the IF statement in most modern programming languages. It allows a line of code or a block of code to be run only if certain conditions are met. If the conditions are not met, the code is skipped, and execution moves to later lines of code.

  7. Using the CASE statement. This is most easily accomplished in all versions of SQL Server using the CASE statement, which acts as a logical IF...THEN...ELSE expression and returns various values depending on the result.

  1. Ludzie szukają również