data

Description

test
Алмат Мейржан
Quiz by Алмат Мейржан, updated more than 1 year ago
Алмат Мейржан
Created by Алмат Мейржан almost 7 years ago
223
0

Resource summary

Question 1

Question
Which symbol do you use if you need to choose all the columns from the table to the result query?
Answer
  • *
  • +
  • All
  • %

Question 2

Question
Which is right order of the following clauses?
Answer
  • SELECT … FROM … GROUP BY … ORDER BY … WHERE
  • SELECT … WHERE … ORDER BY … GROUP BY
  • SELECT … FROM … WHERE … GROUP BY … ORDER BY
  • SELECT … FROM … WHERE … ORDER BY … GROUP BY

Question 3

Question
Which symbol is used to create a substitution variable?
Answer
  • *
  • &
  • _
  • %

Question 4

Question
Which keyword is used to provide an alias to a column?
Answer
  • COLUMN
  • ALIAS
  • IS
  • AS

Question 5

Question
Which command is used to view the structure of the table LOCATIONS?
Answer
  • DESCRIBE LOCATIONS
  • SELECT * FROM LOCATIONS
  • SHOW STRUCTURE LOCATIONS
  • PRINT LOCATIONS

Question 6

Question
Which of the following is a concatenation operator?
Answer
  • *
  • +
  • &
  • ||

Question 7

Question
Which keyword is used to eliminate duplicate rows in the result?
Answer
  • DESCRIBE
  • GROUP BY
  • HAVING
  • DISTINCT

Question 8

Question
Which of the following operations is an analogue to the CONCAT function?
Answer
  • ||
  • +
  • LIKE
  • IN

Question 9

Question
When using LIKE conditions which symbol is used to denote zero or many characters?
Answer
  • *
  • +
  • _
  • %

Question 10

Question
When using LIKE conditions which symbol is used to denote one character?
Answer
  • *
  • +
  • _
  • %

Question 11

Question
Which of the following clauses is used to limit the rows that are retrieved by the query?
Answer
  • WHERE
  • FROM
  • ORDER BY
  • GROUP BY

Question 12

Question
Which of the following clauses is used to sort the rows that are retrieved by the query?
Answer
  • WHERE
  • FROM
  • ORDER BY
  • GROUP BY

Question 13

Question
Which of the following functions extracts a string of determined length?
Answer
  • SUBSTR
  • INSTR
  • CONCAT
  • TRIM

Question 14

Question
Which of the following functions finds the numeric position of a named character?
Answer
  • SUBSTR
  • INSTR
  • CONCAT
  • TRIM

Question 15

Question
Which of the following functions joins two strings together?
Answer
  • CONCAT
  • TRIM
  • SUBSTR
  • INSTR

Question 16

Question
Which of the following functions is not single-row function?
Answer
  • SUM
  • UPPER
  • CONCAT
  • ROUND

Question 17

Question
Which of the following functions is not multiple-row function?
Answer
  • TRUNC
  • SUM
  • AVG
  • COUNT

Question 18

Question
FULL OUTER JOIN is used when
Answer
  • each row of one table must be join with each row of another table
  • each row of one table must be join with each row of another table even if the tables do not have any columns in common
  • the rows from both tables must be displayed even if they do not satisfy the JOIN condition
  • a Cartesian product of the two tables must be displayed

Question 19

Question
Queries that return only one row from the inner SELECT statement are called
Answer
  • Single-column subqueries
  • Multiple-column subqueries
  • Multiple-row subqueries
  • Single-row subqueries

Question 20

Question
Queries that return more than one row from the inner SELECT statement are called
Answer
  • Multiple-row subqueries
  • Single-row subqueries
  • Multiple-column subqueries
  • Single-column subqueries

Question 21

Question
The _______operator compares a value to each value returned by a subquery.
Answer
  • ANY
  • ALL
  • NOT
  • SOME

Question 22

Question
The ________operator compares a value to every value returned by a subquery.
Answer
  • ALL
  • ANY
  • NOT
  • SOME

Question 23

Question
Subqueries have the following characteristics: I. Can pass one row of data to a main statement that contains a single-row operator, such as =, <>, >, >=, <, or <= II. Can pass multiple rows of data to a main statement that contains a multiple-row operator, such as IN III. Are processed first by the Oracle server, after which the WHERE or HAVING clause uses the results
Answer
  • I and III
  • I, II, and III
  • I and II
  • I only

Question 24

Question
A SELECT statement that is embedded in a clause of another SELECT statement is called
Answer
  • subquery
  • inner query
  • outer query
  • main query

Question 25

Question
You can place the subquery in a number of SQL clauses, including the following: I. WHERE clause II. HAVING clause III. FROM clause
Answer
  • I and III
  • I, II and III
  • I and II
  • I only

Question 26

Question
Comparison conditions fall into two classes:
Answer
  • single-row operators (>, =, >=, <, <>, <=) and multiple-column operators (IN, ANY, ALL)
  • single-column operators (>, =, >=, <, <>, <=) and multiple-column operators (IN, ANY, ALL)
  • multiple-row operators (>, =, >=, <, <>, <=) and single-row operators (IN, ANY, ALL)
  • single-row operators (>, =, >=, <, <>, <=) and multiple-row operators (IN, ANY, ALL)

Question 27

Question
The subquery generally executes_________, and its output is used to complete the query condition for the main (or_________) query.
Answer
  • last, outer
  • first, inner
  • last, inner
  • first, outer

Question 28

Question
A subquery must be enclosed in_________________.
Answer
  • curly braces
  • double quotes
  • single quotes
  • parentheses

Question 29

Question
_________ clause can be used and is required in the subquery to perform Top-N analysis.
Answer
  • ORDER BY
  • HAVING
  • WHERE
  • GROUP BY

Question 30

Question
Which of the following operators is equivalent to the IN operator?
Answer
  • < ANY
  • = ALL
  • = ANY
  • > ANY

Question 31

Question
Queries containing set operators are called______________.
Answer
  • outer queries
  • compound queries
  • subqueries
  • inner queries

Question 32

Question
The _____________operator returns all rows that are selected by either query eliminating duplicates.
Answer
  • INTERSECT
  • UNION
  • MINUS
  • UNION ALL

Question 33

Question
Use the ________________operator to return all rows from multiple tables and eliminate any duplicate rows.
Answer
  • UNION ALL
  • UNION
  • MINUS
  • INTERSECT

Question 34

Question
_______________ returns all rows selected by either query, including all duplicates.
Answer
  • NTERSECT
  • MINUS
  • UNION
  • UNION ALL

Question 35

Question
Use the __________________operator to return all rows that are common to multiple queries.
Answer
  • UNION
  • UNION ALL
  • MINUS
  • INTERSECT

Question 36

Question
Use the ______________operator to return rows returned by the first query that are not present in the second query.
Answer
  • MINUS
  • INTERSECT
  • UNION
  • UNION ALL

Question 37

Question
Which statement discards all pending data changes
Answer
  • DISCARD
  • SAVEPOINT
  • ROLLBACK
  • COMMIT

Question 38

Question
Which of the following commands removes rows and a table structure?
Answer
  • REMOVE TABLE
  • ALTER TABLE
  • DROP TABLE
  • DELETE TABLE

Question 39

Question
Which of the following commands is a part of the Data Manipulation Language?
Answer
  • TRUNCATE
  • DROP
  • ALTER
  • SELECT

Question 40

Question
Which of the following commands is a part of the Data Definition Language?
Answer
  • DELETE
  • UPDATE
  • SELECT
  • CREATE

Question 41

Question
Which of the following constraints does not exist?
Answer
  • UNIQUE
  • CHECK
  • NOT NULL
  • DEFAULT

Question 42

Question
Consider the EMPLOYEES table. Which of the following SQL statements is correct to display the last name of the employee with its hire date providing the Employee and Hire Date aliases (case is important)?
Answer
  • SELECT last_name AS 'Employee', hire_date AS 'Hire Date' FROM employees;
  • SELECT last_name "Employee", hire_date "Hire Date" FROM employees;
  • SELECT last_name Employee, hire_date Hire Date FROM employees;
  • SELECT last_name AS Employee, hire_date AS Hire Date FROM employees;

Question 43

Question
Consider the EMPLOYEES table. Which of the following SQL statements is correct to provide the sentence in the format "King has been working since 01.01.1987" with "Employee Information" alias?
Answer
  • SELECT last_name || ' has been working since ' || hire_date Employee Information FROM employees;
  • SELECT last_name || ' has been working since ' || hire_date 'Employee Information' FROM employees;
  • SELECT last_name || " has been working since " || hire_date "Employee Information" FROM employees;
  • SELECT last_name || ' has been working since ' || hire_date "Employee Information" FROM employees;

Question 44

Question
What will be the result of the following SQL statement?
Answer
  • he number of employees within each department will be displayed
  • An error will occur since the GROUP BY clause is missing
  • The unique department ids will be displayed
  • The number of departments will be displayed

Question 45

Question
Which of the following SQL statements will not generate an error?
Answer
  • SELECT department_id Dep, COUNT(last_name) Num FROM employees GROUP BY department_id HAVING Num > 5
  • SELECT department_id Dep, COUNT(last_name) FROM employees GROUP BY Dep
  • SELECT last_name Name FROM employees WHERE Name like 'K%'
  • SELECT last_name Name FROM employees ORDER BY Name

Question 46

Question
Consider the EMPLOYEES table. Which condition in the WHERE clause limit the employees to those whose salary is greater than 5000 but less than 18000?
Answer
  • WHERE salary > 5000 AND salary > 18000
  • WHERE salary > 5000 AND salary < 18000
  • WHERE salary < 5000 AND salary > 18000
  • WHERE salary > 5000 OR salary < 18000

Question 47

Question
Consider the EMPLOYEES table. Which condition in the WHERE clause limit the employees to IT programmers with salary greater than 5000?
Answer
  • WHERE salary > 5000 AND job_id = 'IT_PROG'
  • WHERE salary > 5000 OR job_id = 'IT_PROG'
  • WHERE salary > 5000 AND job_id = "IT_PROG"
  • WHERE salary > 5000 AND job_id = IT_PROG

Question 48

Question
Consider the EMPLOYEES table. Which condition in the WHERE clause limit the employees to those who work in the departments 90 and 60?
Answer
  • WHERE department_id BETWEEN 60 AND 90
  • WHERE department_id BETWEEN 90 AND 60
  • WHERE department_id = 90 OR department_id = 60
  • WHERE department_id = 90 AND department_id = 60

Question 49

Question
Consider the EMPLOYEES table. Which condition in the WHERE clause limit the employees to those who do not work in the departments 90 and 60?
Answer
  • WHERE department_id = 90 OR department_id = 60
  • WHERE department_id NOT IN (90, 60)
  • WHERE department_id = 90 AND department_id = 60
  • WHERE department_id IN (90, 60)

Question 50

Question
Consider the EMPLOYEES table. Which condition in the WHERE clause limit the employees to those whose last name and first name starts with the letter ‘K’?
Answer
  • WHERE last_name LIKE 'K%' and first_name LIKE 'K%'
  • WHERE last_name LIKE 'K_' and first_name LIKE 'K_'
  • WHERE last_name = 'K%' and first_name = 'K%'
  • WHERE last_name and first_name = 'K%'
Show full summary Hide full summary

Similar

Statistics, Data and Area (Semester 2 Exam)
meg willmington
Mathematics
Corey Lance
Chapter 7: Investigating Data
Sarah L
Maths Summarising Data
Will Thorpe
GCSE Computing - 4 - Representation of data in computer systems
lilymate
STEM AND LEAF DIAGRAMS
Elliot O'Leary
TYPES OF DATA
Elliot O'Leary
AS level geography- Geographical Skills
beth2384
F453 Data Structures - Stacks and Queues
harvs899
2.1.4 Data Representation
Jake Youd