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. When returning multiple rows - a subquery must contain the _____ - _____ - _____ - or ______ operator - otherwise Oracle will return an error
IN ANY ALL SOME
Details
4000
F12
2. What is the maximum value for a column defined as NUMBER(4 -2)?
99.99
4
Recursive
LIKE
3. Which one of the following string functions tells you how many characters are in a string?
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.
LENGTH
**** 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
Running a script file
4. ___________ subqueries allow you to reference columns from the outer query and execute the inner query repeatedly
BETWEEN
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
99.99
Correlated
5. Joins involving multiple columns must always follow the ____________ relationship path.
Primary key/foreign key
Columns
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.
Same
6. Explain how Oracle treats locks when a database is being updated and needs to be viewed by other users.
RENAME just_two_more_weeks TO finally_i
DESC dict;
RIGHT LEFT JOIN
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
7. In a view you can give a column a different name than it has in the...
Parent table
ANSI
DICTIONARY
Non-matching rows
8. Self-joins are useful for performing comparisons and checking for ___________ in data.
V$
Default is 14; when you use the default - you repeat the heading every 14 rows.
Inconsistencies
LIKE
9. List the steps performed by a correlated subquery.
SYSDATE
LIKE
**** 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
Results
10. To restart a sequence at a lower number - you can drop and ________ the sequence.
Re-create
MODIFY
**** 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
The indexed column is part of an expression. In this case - consider creating a function-based index instead
11. What are the main components of a ROWID?
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.
Location of the file
Equijoin and correlated subquery
Same
12. ____________ are useful for analyzing and exploring the relationships within your data
Non-matching rows
Self-joins
RENAME - COPY - DROP - TRUNCATE - LOCK - & COMMENT
Correlated
13. The query retrieves more than 5 to 15 percent of the rows
Multiple rows
SET clause of an UPDATE statement
DD-MON-YY
The indexed column is part of an expression. In this case - consider creating a function-based index instead
14. Comparison operators can compare multiple _________________.
Fractional seconds
Nested
Columns
ROLLBACK
15. The ____________ keywords and the USING clause of the ANSI join syntax are mutually exclusive.
Running a script file
UNION
NATURAL JOIN
INNER JOIN
16. Oracle uses the outer join operator to indicate that nulls are shown for...
Non-matching rows
A correct statement
When the table is small (unless your business rules require you too)
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
17. To revert back to a state that happened before you ran your change statement - you issue a ____________ command.
Actual column
COUNT(registration_date) - AVG (capacity) - MIN (capacity) - MAX (capacity)
ROLLBACK
CLOB
18. Explain why constraints are used when building tables.
Warning
: Invalid argument supplied for foreach() in
/var/www/html/basicversity.com/show_quiz.php
on line
183
19. When disabling a unique or primary key - you can keep the index if you specify the __________________ clause in the ALTER TABLE statement.
Data
KEEP INDEX
Equijoin and correlated subquery
Null
20. A join across three tables can be expressed with the ________ join syntax.
Equijoin
ANSI
Script
STORAGE
21. SQL Developer provides an extensive list of useful reports and offers the capability to create your own...
Crow's foot
Correlated
User-defined reports
CLOB
22. The DUAL table can be used for...
DESC dict;
Testing functions
Correlated
@ or START
23. List 6 Table-Related Menu Choices
MINUS
Export Data
RENAME - COPY - DROP - TRUNCATE - LOCK - & COMMENT
DECODE
24. When you want to run a script in either SQL*Plus or SQL Developer - you can use a ______ or the _________ command.
Extra spaces
Running a script file
@ or START
Results
25. Instead of using the Oracle Outer Join Operator or the ANSI syntax - you can achieve the same result with two SQL statements: ____________ and a ____________
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
Equijoin and correlated subquery
MODIFY
Testing functions
26. A _____ is a query definition stored in the database that looks just like a table - but does not have any physical rows
Crow's foot
NATURAL JOIN
Month ddth - yyyy
X
27. To equijoin a table with another table involves matching the...
Common column value
Re-create
SUM
RENAME - COPY - DROP - TRUNCATE - LOCK - & COMMENT
28. LINESIZE
Command determines the total number of characters SQL *Plus displays in on line before beginning a new line.
The way NULL values are treated
UTC
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
29. What is the first column of a composite index called?
DESC dict;
User-defined reports
Leading-edge
Scale
30. What is the main difference between the NOT EXISTS and the NOT IN operators?
The way NULL values are treated
Run scripts
Scalar
Time zone
31. The time zone displacement value indicates the time difference from _______.
UTC
Default is 14; when you use the default - you repeat the heading every 14 rows.
USER_ - ALL_ - DBA_ - and V$
When the table is small (unless your business rules require you too)
32. You use the _________ keyword to add columns or constraints to a table.
Static or dynamic
VALUES
Actual column
ADD
33. Explain what is found in the All Objects report folder in SQL Developer
Twice
Lists all objects accessible for the chosen database connection. Also lists a helpful dependencies report for accessing change impact.
Equijoin and identical column names
Groups
34. What is the Oracle data dictionary called that contains a set of tables and views containing the data about the database?
Retrieve
Equijoin and identical column names
ALL_OBJECTS
Time zone
35. All SQL statements contained within a script must end with a _______________ - even if they are done in SQL Developer.
Non-matching rows
A correct statement
Data
Semicolon or forward slash
36. Converting a text literal to DATE format requires the use of the...
LENGTH
A correct statement
Extra spaces
TO_CHAR function
37. To join four tables - you must have at least _____ join conditions.
Three
Month ddth - yyyy
Business problems
Export Data
38. The data type definitions NUMBER(10) and NUMBER(10 -0) are the...
F12
Same
INTERSECT
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.
39. You can __________ DISTINCT and a GROUP BY clause in the same SELECT statement.
Location of the file
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
Combine
Inconsistencies
40. The purpose of the HAVING clause is to eliminate___________.
Results
Groups
Running a script file
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
41. Write a statement for SQL*Plus that shows the dictionary.
DESC dict;
ON
Surrogate
DECODE
42. The ________________ is a type of statement whereby you retrieve data that exists in one table - but not in another.
MINUS
Fractional seconds
Both MIN and MAX
+
43. When you have issued a DELETE command - you can still ________ those rows and restore the information.
A correct statement
Retrieve
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
CLOB
44. Write the syntax to rename index just_two_more_weeks_i to finally_i
Retrieve
Scale
RENAME just_two_more_weeks TO finally_i
BETWEEN
45. In SQL Developer field names and table names are shown in the color _______.
ALL_OBJECTS
Surrogate key
Black
ANSI
46. What is the tab in SQL Developer where data dictionary view information can be found?
@ or START
Static or dynamic
USER_ - ALL_ - DBA_ - and V$
Details
47. If a graphical representation of a table's box has __________ it means that the relationship is identifying.
COUNT(registration_date) - AVG (capacity) - MIN (capacity) - MAX (capacity)
Columns
Equijoin and correlated subquery
Rounded edges
48. The ______ operator compares a list of values for equivalency
ANY
SELECT DISTINCT menu FROM restaurant
Crow's foot
Lists all objects accessible for the chosen database connection. Also lists a helpful dependencies report for accessing change impact.
49. What is the most common DATE format found in SQL?
Location of the file
Three
DD-MON-YY
Self-joins
50. __________________ inserts the current date and time.
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
LENGTH
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
SYSDATE