Where Clause in SQL
The WHERE clause is used to add a condition to filter the records when we want to fetch the specific records instead of all records. Syntax: To specify a condition we can use any logical operator like >, <, =, LIKE, NOT etc. Example: Output:
Alias in SQL
The ALIAS statement is used to temporarily rename a table or column in a SQL statement. Syntax: Example: Output:
Not Between Operator in SQL
The BETWEEN operator is used to select values within a range. The values can be numbers, dates or text. Syntax: The value of the conditioned column should not be in the given range specified by NOT BETWEEN operator. Example: Output:
Between Operator in SQL
The BETWEEN operator is used to select values within a range. The values can be numbers, dates or text. Syntax: The value of the conditioned column should be in the given range specified by BETWEEN operator. Example: Output:
Not In Operator in SQL
The NOT IN operator is used to reduce the multiple or conditions by specifying the multiple values in a where clause. Syntax: The value of the conditioned column should not be equal to the any of the specified values in the NOT IN operator. Example: Output:
SQL Select in Operator
The IN operator is used to reduce the multiple or conditions by specifying the multiple values in a where clause. Syntax: The value of the conditioned column should be equal to the any one of the specified values in the IN operator. Example: Output:
Select Top in SQL
The SELECT TOP statement is used to retrieve the top specified number of rows from a table. Syntax: Where n is the number of rows. Example: Output:
Distinct Keyword in SQL
The DISTINCT keyword is used to retrieve the unique records by eliminating the all duplicate records. Syntax: Example: Output: