SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
Oracle SQL
Start Test
Study First
Subjects
:
oracle
,
it-skills
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. The TIMESTAMP WITH LOCAL TIME ZONE data type allows...
Fractional seconds
Rounded edges
4000
@ or START
2. What is the keyboard shortcut for the ROLLBACK command?
F12
KEEP INDEX
The main components of a ROWID are the data object number - the number of the data block - the numbers of rows within the data block - and the data file number.
Optional
3. When returning multiple rows - a subquery must contain the _____ - _____ - _____ - or ______ operator - otherwise Oracle will return an error
IN ANY ALL SOME
Command determines the total number of characters SQL *Plus displays in on line before beginning a new line.
Recursive
Common column value
4. If a graphical representation of a table's box has __________ it means that the relationship is identifying.
Another null
Rounded edges
SELECT SYSDATE+1/96 - FROM dual
Primary key/foreign key
5. It is considered good form to put all SQL commands in...
Data
ANSI
Details
All caps
6. How many characters can you have using the VARCHAR data type?
Results
Constraints are used to enforce the business rules of a system. For instance - 'The salary of an employee may not be a negative number' may be enforced with a check constraint on the salary column. Constraints also ensure integrity and data consisten
DESC dict;
4000
7. Users can only see changes made to a database once they have been...
When the table is small (unless your business rules require you too)
Optional
Committed
SET clause of an UPDATE statement
8. The ___________ operator tests whether a matching row cannot be found.
The SPOOL command - together with a file name - spools any subsequently issued SQL Plus or SQL command to a file. Just as with other file names - you can add a path to store the file in a directory other than your SQL Plus default directory. SQL Deve
DROP INDEX need_to_pass_i
X
Structured Query Language
9. Write the syntax to rename index just_two_more_weeks_i to finally_i
RENAME just_two_more_weeks TO finally_i
Same
Default is 14; when you use the default - you repeat the heading every 14 rows.
999999.9999
10. Instead of using the Oracle Outer Join Operator or the ANSI syntax - you can achieve the same result with two SQL statements: ____________ and a ____________
Equijoin and correlated subquery
Details
Null
LENGTH
11. _________ and __________ functions are opposites of each other and provide a value in a group of rows.
Both MIN and MAX
4
Recursive
Location of the file
12. The COUNT function is useful for determining whether a table has...
COMMIT
Null
Data
Equijoin and correlated subquery
13. NUMBER functions can be...
Nested
Results
DROP INDEX need_to_pass_i
RENAME - COPY - DROP - TRUNCATE - LOCK - & COMMENT
14. When using the data NUMBER(10 -4) there will be _______ digits following the decimal point.
BETWEEN
4
Asterisk
Location of the file
15. Explain how the SPOOL command is used and what program it can be used in.
Subqueries allow you to nest multiple queries into each other. This gives you the ability to use one statement to break down a problem into individual components. Without nesting queries - you would be required to have multiple queries which could be
Orable's flashback query feature allows you to look at values of a query at a specific time in the past - such as before specfic DML statements occured. This can be usefull in case a suer accidentally performs an unintended but committed DML change.
The SPOOL command - together with a file name - spools any subsequently issued SQL Plus or SQL command to a file. Just as with other file names - you can add a path to store the file in a directory other than your SQL Plus default directory. SQL Deve
LIKE
16. What is the name of the view where you can find the collection of static and data dictionary tables and views - along with their descriptions?
DICTIONARY
Mathematical equations
LIKE
The way NULL values are treated
17. List 4 aggregate functions
Leading-edge
Testing functions
When you want to run the same script repeatedly - but want to be able to change a variable you would use a substitution variable. During the execution of the script the user will be prompted to input the variable to use.
COUNT(registration_date) - AVG (capacity) - MIN (capacity) - MAX (capacity)
18. What is the first column of a composite index called?
Same
ANSI
Leading-edge
Logical unit of work
19. When you INSERT new information into a table - it is followed with a _______ keyword that contains the information that is going to be added to the table.
Actual column
VALUES
Non-matching rows
Combine
20. Match each of the SQL commands on the left with a verb from the list.
Rounded edges
SELECT SYSDATE+1/96 - FROM dual
Control - Revoke - Define - TRUNCATE Manipulate - MERGE
IN ANY ALL SOME
21. Explain how you can optimize your queries with subqueries and the main advantage of doing so.
BETWEEN
Fractional seconds
Actual column
Subqueries allow you to nest multiple queries into each other. This gives you the ability to use one statement to break down a problem into individual components. Without nesting queries - you would be required to have multiple queries which could be
22. What is the Oracle data dictionary called that contains a set of tables and views containing the data about the database?
ALL_OBJECTS
When you issue a INSERT - UPDATE - DELETE - or MERGE statement - Oracle automatically locks the modified rows. The lock prevents other sessions from making changes to these rows. The lock is released when the session initiating change commits or roll
4
COUNT(registration_date) - AVG (capacity) - MIN (capacity) - MAX (capacity)
23. The RTRIM function is useful for eliminating ________ in a string.
Three
Extra spaces
Nested
UNION operator
24. What do views do that makes them so useful for security?
Optional
BETWEEN
USER_ - ALL_ - DBA_ - and V$
Hide data
25. PAGESIZE
Mathematical equations
Default is 14; when you use the default - you repeat the heading every 14 rows.
Equijoin
Surrogate key
26. SQL Developer's ____________________ option allows you to selectively export certain rows and columns.
DICT_COLUMNS
User-defined reports
ANSI
Export Data
27. You can simplify the writing of SQL statements by writing SQL _________ that generate and execute other SQL statements.
Script
The SPOOL command - together with a file name - spools any subsequently issued SQL Plus or SQL command to a file. Just as with other file names - you can add a path to store the file in a directory other than your SQL Plus default directory. SQL Deve
Surrogate key
FALSE
28. SELECT * FROM instructor ORDER BY phone
Hide data
X
A correct statement
Data
29. When you create a report in SQL Developer all the column names must match identically the names of the columns found in the tables you are referencing.
DROP INDEX need_to_pass_i
FALSE
A correct statement
The way NULL values are treated
30. LINESIZE
Command determines the total number of characters SQL *Plus displays in on line before beginning a new line.
Leading-edge
ROLLBACK
The indexed column is part of an expression. In this case - consider creating a function-based index instead
31. The query retrieves more than 5 to 15 percent of the rows
Retrieve
Null
When you issue a INSERT - UPDATE - DELETE - or MERGE statement - Oracle automatically locks the modified rows. The lock prevents other sessions from making changes to these rows. The lock is released when the session initiating change commits or roll
The indexed column is part of an expression. In this case - consider creating a function-based index instead
32. Checks whether any value in the list makes the condition true.
Time zone
Any
MODIFY
USER_ - ALL_ - DBA_ - and V$
33. You use the _________ keyword to add columns or constraints to a table.
Groups
Actual column
999999.9999
ADD
34. What is the command you would type into SQL*Plus if you needed to know the definition for each column of a table?
All
Crow's foot
Hide data
DICT_COLUMNS
35. List the steps performed by a correlated subquery.
**** Select a row from the outer query - Determine the value of the correlated column - Execute the inner query for each record of the outer query. - Feed the results of the inner query to the outer query and evaluate it. It if satisfies the criteria
Orable's flashback query feature allows you to look at values of a query at a specific time in the past - such as before specfic DML statements occured. This can be usefull in case a suer accidentally performs an unintended but committed DML change.
ANY
DICT_COLUMNS
36. A transaction is a...
UNION
Logical unit of work
DESC dict;
UTC
37. A _____ is a query definition stored in the database that looks just like a table - but does not have any physical rows
COMMIT
The main components of a ROWID are the data object number - the number of the data block - the numbers of rows within the data block - and the data file number.
Committed
X
38. Self-joins are useful for performing comparisons and checking for ___________ in data.
RENAME - COPY - DROP - TRUNCATE - LOCK - & COMMENT
Inconsistencies
Null
V$
39. To join four tables - you must have at least _____ join conditions.
Twice
Any
Three
DECODE
40. Explain the steps needed to run a script in SQL Developer
Common column value
GROUP BY
4
Load the file into the SQL Statement Box - by opening the location the file is stored and inserting it into the statement Box. Next you can press the F5 key.
41. The term ____________ ___________ is used to express a join that satisfies the join condition.
Structured Query Language
Logical unit of work
Export Data
INNER JOIN
42. Joins involving multiple columns must always follow the ____________ relationship path.
Primary key/foreign key
Export Data
VALUES clause of an INSERT statement
GROUP BY
43. FEEDBACK
MODIFY
Same
Primary key/foreign key
Command returns the number of records returned by a query.
44. Explain how Oracle treats locks when a database is being updated and needs to be viewed by other users.
Constraints are used to enforce the business rules of a system. For instance - 'The salary of an employee may not be a negative number' may be enforced with a check constraint on the salary column. Constraints also ensure integrity and data consisten
Details
When you issue a INSERT - UPDATE - DELETE - or MERGE statement - Oracle automatically locks the modified rows. The lock prevents other sessions from making changes to these rows. The lock is released when the session initiating change commits or roll
The way NULL values are treated
45. What is the maximum value for a column defined as NUMBER(4 -2)?
99.99
When the table is small (unless your business rules require you too)
Hide data
The main components of a ROWID are the data object number - the number of the data block - the numbers of rows within the data block - and the data file number.
46. Explain the differences in how an ANSI Full Outer Join and a Full Outer Join using the UNION Operator work
X
Control - Revoke - Define - TRUNCATE Manipulate - MERGE
99.99
BETWEEN
47. Which format mask displays December 31st - 1999?
Month ddth - yyyy
User-defined reports
Retrieve
X
48. What is the most common DATE format found in SQL?
F12
DD-MON-YY
X
Command determines the total number of characters SQL *Plus displays in on line before beginning a new line.
49. The COUNT function uses the __________ wildcard.
2000
Asterisk
DICT_COLUMNS
UTC
50. You can __________ DISTINCT and a GROUP BY clause in the same SELECT statement.
VALUES clause of an INSERT statement
Leading-edge
Combine
Committed