Please match the keyword or operator from the list below to its correct explanation and syntax in the table. Replace ? with a correct option from the following list: OR, Arithmetic operators, AND, Comparison operators, NOT, IS NOT NULL, DATE(), BETWEEN, IN, LIKE, IS NULL Keyword/Operator Explanation Syntax ? Compare left-hand side value to the right-hand side value SELECT * from WHERE | HAVING Operators include =, <>, <, >, <=, >= ? Mathematical operators SELECT ; Operators include Addition (+), subtraction (-), multiplication (*), division (/) and modulo (remainder, %) ? Displays rows when all conditions are met SELECT * FROM WHERE AND ; ? Displays rows when any condition is met SELECT * FROM WHERE OR ; ? Display records if the condition is NOT met SELECT * FROM WHERE NOT ; ? Displays records in the range for continuous values OR selects rows between two values SELECT * FROM WHERE BETWEEN AND ; ? Display records where multiple values for a categorical attribute are met OR displays records IN the list SELECT * FROM WHERE IN (, , …); ? Matching a specific pattern of a string SELECT * FROM WHERE LIKE ; Underscore (_) matches single character Percent (%) matches any number of characters ? To display rows where the value is equal to NULL SELECT * FROM WHERE IS NULL; ? Displays rows where the value is not equal to NULL SELECT * FROM WHERE IS NOT NULL; ? Declaring dates in SQL SELECT DATE(‘YYYY-MM-DD’);
Please match the keyword or operator from the list below to its correct explanation and syntax in the table.
Replace ? with a correct option from the following list: OR, Arithmetic operators, AND, Comparison operators, NOT, IS NOT NULL, DATE(), BETWEEN, IN, LIKE, IS NULL
Keyword/Operator |
Explanation |
Syntax |
? |
Compare left-hand side value to the right-hand side value |
SELECT * from <table name> WHERE | HAVING <column name> <operator> <value> Operators include =, <>, <, >, <=, >= |
? |
Mathematical operators |
SELECT <number 1> <operator> <number 2>; Operators include Addition (+), subtraction (-), multiplication (*), division (/) and modulo (remainder, %) |
? |
Displays rows when all conditions are met |
SELECT * FROM <table name> WHERE <condition 1> AND <condition 2>; |
? |
Displays rows when any condition is met |
SELECT * FROM <table name> WHERE <condition 1> OR <condition 2>; |
? |
Display records if the condition is NOT met |
SELECT * FROM <table name> WHERE NOT <condition>; |
? |
Displays records in the range for continuous values OR selects rows between two values |
SELECT * FROM <table name> WHERE <column name> BETWEEN <value1> AND <value2>; |
? |
Display records where multiple values for a categorical attribute are met OR displays records IN the list |
SELECT * FROM <table name> WHERE <column name> IN (<value1>, <value2>, …);
|
? |
Matching a specific pattern of a string
|
SELECT * FROM <table name> WHERE <column name> LIKE <pattern>; Underscore (_) matches single character Percent (%) matches any number of characters |
? |
To display rows where the value is equal to NULL |
SELECT * FROM <table name> |
? |
Displays rows where the value is not equal to NULL |
SELECT * FROM <table name> |
? |
Declaring dates in SQL |
SELECT DATE(‘YYYY-MM-DD’); |
Trending now
This is a popular solution!
Step by step
Solved in 2 steps