Marking Scheme Updated 2024/2025
And operator - correct answer - it displays a record if more than one condition is true
Avg() function - correct answer - it returns the average value of a numeric column.
Between operator - correct answer - it allows you to specify a range of numeric values
in a search.
Distinct operator - correct answer - it is used to eliminate duplicate rows in a query
result.
In operator - correct answer - it allows you to specify a list of character strings to be
included in a search
Join clause - correct answer - it is used to combine rows from more than one table,
based on a common field between them.
Like operator - correct answer - it allows you to specify partial character strings in a
"wildcard" sense.
Or operator - correct answer - it displays a record it either the first condition or the
second condition is true.
Order by clause - correct answer - it simply takes the result of a sql query and orders
them by one or more specified attributes.
Select command - correct answer - data retrieval in sql is accomplished with the select
command.
, Subquery - correct answer - when on select statement is "nested" within another in a
format, it is known as subquery.
Common ddl commands: - correct answer - create
- alter
- drop
- truncate
- rename
Common dml commands: - correct answer - select
- insert
- update
- delete
- merge
Write the basic sql query command: - correct answer select<columns>
From<table>
Where<predicates identifying rows to be included>
Write the sql query to "find the commission percentage and year of hire of salesperson
186": - correct answer select commperct, yearhire
From salesperson
Where spnum=186;
Write the sql query to "retrieve the entire record for salesperson 186": - correct answer
select *
From salesperson
Where spnum=186;