Yahoo Poland Wyszukiwanie w Internecie

Search results

  1. Definition and Usage. The IF () function returns a value if a condition is TRUE, or another value if a condition is FALSE. Syntax. IF (condition, value_if_true, value_if_false) Parameter Values. Technical Details. More Examples. Example. Return 5 if the condition is TRUE, or 10 if the condition is FALSE: SELECT IF(500<1000, 5, 10);

  2. 1 cze 2022 · In this article, we will explain the diversities of MySQL IF function and MySQL IF statement and show their usage examples. Also, we will review other MySQL functions.

  3. www.mysqltutorial.org › mysql-stored-procedure › mysql-if-statementMySQL IF Statement - MySQL Tutorial

    The IF statement allows you to evaluate one or more conditions and execute the corresponding code block if the condition is true. The IF statement has three forms: IF...THEN statement: Evaluate one condition and execute a code block if the condition is true.

  4. www.mysqltutorial.org › mysql-control-flow-functions › mysql-if-functionMySQL IF Function - MySQL Tutorial

    MySQL IF function Examples. Let’s practice with several examples to see how the MySQL IF function works. A simple IF function example. You can use the IF function directly in the SELECT statement without the FROM and other clauses as follows: SELECT IF (1 = 2, 'true', 'false'); -- false Code language: SQL (Structured Query Language) (sql) Try ...

  5. 22 lut 2017 · In a procedure the use of an IF is pretty straight forward: IF (yourCondition [logical operator(OR, AND) another condition] ) THEN. So in a practical example: .... DECLARE m integer; DECLARE n integer; SET m = 1; SET n = 0; IF ((m>n AND m=1 AND n=0) OR m=n)THEN.

  6. 6 cze 2024 · The IF () function in MySQL returns a value if the condition is TRUE and another value if the condition is FALSE. The MySQL IF () function can return values that can be either numeric or strings, depending upon the context in which the function is used.

  7. 11 lip 2024 · The IF function in MySQL allows for conditional logic to return specific results based on the evaluation of a condition. In this specific IF function: IF(1 > 3, 'true', 'false'): The IF function takes three arguments: The first argument is the condition to evaluate (1 > 3). The second argument is the value to return if the condition is true ...

  1. Ludzie szukają również