NULL

Filtering NULL IN SQL

Filteing in SQL is achieved by the following functions: Where Cloase Having Clause&lt If you ahve to select elements from a table that has nulls, you can use the following query — Selecting rows where a specific column has null values SELECT * FROM your_table_name WHERE your_column_name IS NULL; Filter out NOT NULL — Selecting […]

Filtering NULL IN SQL Read More »

NULLIF

Syntax NULLIF(expr1, expr2) NULLIF compares expr1 and expr2 If they are equal, then the function returns null If they are not equal, then the function returns expr1 f both arguments are numeric data types, then Oracle Database determines the argument with the higher numeric precedence, implicitly converts the other argument to that data type, and returns that data type.If the

NULLIF Read More »

COALESCE() Function

The COALESCE() function returns the first non-null value in a list.The COALESCE function takes two or more compatible arguments and returns the first argument that is not null. You must specify at least two expressions If all occurrences of expr evaluate to null, then the function returns null. The result is null only if all the arguments

COALESCE() Function Read More »

NVL2()

Syntax. NVL2( string1, value_if_not_null, value_if_null )

The Oracle/PLSQL NVL2 function extends the functionality found in the NVL function NVL2 lets you determine the value returned by a query based on whether a specified expression is null or not null. If expr1 is not null, then NVL2 returns expr2. If expr1 is null, then NVL2 returns expr3. The argument expr1 can have any data type. The arguments expr2 and expr3 can have

NVL2() Read More »

NVL()

Syntax: NVL(string1, replace_with) The NVL function accepts two arguments: The first argument takes the name of the expression to be evaluated. The second argument specifies the value that the function returns when the first argument evaluates to NULL.   In SQL, NVL is a substitution function that displays one value if another value is NULL.

NVL() Read More »

Scroll to Top