Accounting
Anthropology
Archaeology
Art History
Banking
Biology & Life Science
Business
Business Communication
Business Development
Business Ethics
Business Law
Chemistry
Communication
Computer Science
Counseling
Criminal Law
Curriculum & Instruction
Design
Earth Science
Economic
Education
Engineering
Finance
History & Theory
Humanities
Human Resource
International Business
Investments & Securities
Journalism
Law
Management
Marketing
Medicine
Medicine & Health Science
Nursing
Philosophy
Physic
Psychology
Real Estate
Science
Social Science
Sociology
Special Education
Speech
Visual Arts
Design
Q:
SQL supports the conditionalexecution of procedures (if...then...else statements) that are typically supported by a programming language.
Q:
UNION, INTERSECT, and MINUS work properly only if relations are union-compatible, which means that the names of the relation attributes and their data types must be different.
Q:
Triggers are critical to proper database operation and management. What are some of the ways that triggers are used?
Q:
Describe the characteristics of an Oracle sequence.
Q:
What are SQL functions and when are they used? Provide a couple of examples of situations in which they are necessary.
Q:
What are the four different result types that can be returned from a subquery? For each type, explain what it is and when it is used.
Q:
Explain the different basic types of join operations. What are they and how do they work?
Q:
A row-level triggerrequires use of the ____________________ keywords. This type of trigger is executed once for each row affected by the triggering statement.
Q:
Using Oracle ____________________, you can write a PL/SQL code block by enclosing the commands inside BEGIN and END clauses.
Q:
A(n) ____________________ view is a view that can be used to update attributes in the base table(s) that are used in the view.
Q:
A(n) ____________________ routine pools multiple transactions into a single batch to update a master table field in a single operation.
Q:
In an Oracle sequence, the ____________________ pseudo-column retrieves the current value of a sequence.
Q:
In MS Access, you can use the ____________________ data type to define a column in your table that will be automatically populated with unique numeric values.
Q:
If the DBMS does not support the INTERSECT statement, you can use a(n) ____________________ subquery to achieve the same result.
Q:
The ____________________ statement in SQL combines rows from two queries and returns only the rows that appear in the first set but not in the second.
Q:
The ____________________ statement can be used to combine rows from two queries, returning only the rows that appear in both sets.
Q:
A(n) ____________________ query can be used to produce a relation that retains the duplicate rows.
Q:
The ____________________ statement combines rows from two or more queries without including duplicate rows.
Q:
The ____________________ function compares an attribute or expression with a series of values and returns an associated value or a default value if no match is found.
Q:
____________________ functions allow you to take a value of a given data type and convert it to the equivalent value in another data type.
Q:
Oracle uses the ____________________ function to extract the various parts of a date.
Q:
A(n) ____________________ subquery is a subquery that executes once for each row in the outer query.
Q:
The use of the ____________________ operator allows you to compare a single value with a list of values returned by the first subquery (sqA) using a comparison operator other than EQUALS.
Q:
The IN subquery uses a(n) ____________________ operator.
Q:
The ____________________ clause is used to restrict the output of a GROUP BY query by applying a conditional criteria to the grouped rows.
Q:
When using a subquery, the output of a(n) ____________________ query is used as the input for the outer query.
Q:
The ____________________ outer join returns not only the rows matching the join condition (that is, rows with matching values in the common column), but also the rows in the left-side table with unmatched values in the right-side table.
Q:
An alternate syntax for a join is SELECT column-list FROM table1 JOIN table2 ____________________ (common-column).
Q:
A(n) ____________________ join returns all rows with matching values in the matching columns and eliminates duplicate columns.
Q:
A(n) ____________________ join performs a relational product (also known as the Cartesian product) of two tables.
Q:
A(n) ____________________ joinreturns not only the matching rows but also the rows with unmatched attribute values for one or both tables to be joined.
Q:
How do you delete a table from the database? Provide an example.
Q:
What are the wildcard characters that are used with the LIKE command? Provide one or more examples of each.
Q:
What is a subquery? When is it used? Does the RDBMS deal with subqueries any differently from normal queries?
Q:
What command is used to save changes to the database? What is the syntax for this command?
Q:
What is a schema? How many schemas can be used in one database?
Q:
An alias is especially useful when a table must be joined to itself in a(n) ____________________ query.
Q:
A(n) ____________________ is performed when data is retrieved from more than one table at a time.
Q:
The ____________________ clause of the GROUP BY statement operates very much like the WHERE clause in the SELECT statement.
Q:
Rows can be grouped into smaller collections quickly and easily using the SQL ____________________ clause.
Q:
A(n) ____________________ order sequence is a multilevel ordered sequence that can be created easily by listing several attributes, separated by commas, after the ORDER BY clause.
Q:
A table can be deleted from the database by using the ____________________ command.
Q:
If you add a new column to a table that already has rows, the existing rows will default to a value of ____________________ for the new column.
Q:
A specialty field in mathematics, known as ____________________ algebra, is dedicated to the use of logical operators.
Q:
In SQL, all ____________________ expressions evaluate to true or false.
Q:
The ____________________ command, coupled with appropriate search conditions, is an incredibly powerful tool that enables you to transform data into information.
Q:
A(n) ____________________, also known as a nested query or an inner query, is a query that is embedded (or nested) inside another query.
Q:
A(n) ____________________ character is a symbol that can be used as a general substitute for other characters or commands.
Q:
In an INSERT command, you can indicate just the attributes that have required values by listing the ____________________ inside parentheses after the table name.
Q:
To delete an index, use the ____________________command.
Q:
A common practice is to create a(n) ____________________ on any field that is used as a search key, in comparison operations in a conditional expression, or when you want to list rows in a specific order.
Q:
Using the ____________________ command, SQL indexes can be created on the basis of any selected attribute.
Q:
____________________ words are words used by SQL to perform specific functions.
Q:
In a 1:M relationship, you must alwayscreate the table for the ____________________ side first.
Q:
If your integer values are relatively small, use ____________________ instead of INT.
Q:
DATE() and SYSDATE are special functions that return today's date in MS Access and ____________________, respectively.
Q:
U.S. state abbreviations are always two characters, so ____________________(2) is a logical choice for the data type representing a state column.
Q:
With the exception of the database ____________________ process, most RDBMS vendors use SQL that deviates little from the ANSI standard SQL.
Q:
A(n) ____________________ is a logical group of database objects, such as tables and indexes, that are related to each other.
Q:
The basic SQL vocabulary has fewer than ____________________ words.
Q:
In the SQL environment, the word ____________________covers both questions and actions.
Q:
The query to join the P_DESCRIPT and P_PRICE fields from the PRODUCT table and the V_NAME, V_AREACODE, V_PHONE and V_CONTACT fields from the VENDOR table, where the values of V_CODE match and the output is ordered by the price is ____.a. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE <> VENDOR.V_CODE; ORDER BY P_PRICE;b. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE => VENDOR.V_CODE; ORDER BY P_PRICE;c. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE <= VENDOR.V_CODE; ORDER BY P_PRICE;d. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE = VENDOR.V_CODE; ORDER BY P_PRICE;
Q:
The query to join the P_DESCRIPT and P_PRICE fields from the PRODUCT table and the V_NAME, V_AREACODE, V_PHONE, and V_CONTACT fields from the VENDOR table where the values of V_CODE match is ____.
a. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE <> VENDOR.V_CODE;
b. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE = VENDOR.V_CODE;
c. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE <= VENDOR.V_CODE;
d. SELECT P_DESCRIPT, P_PRICE, V_NAME, V_CONTACT, V_AREACODE, V_PHONE FROM PRODUCT, VENDOR WHERE PRODUCT.V_CODE => VENDOR.V_CODE;
Q:
The SQL aggregate function that gives the average for the specific column is ____.a. COUNT b. AVG c. MAXd. SUM
Q:
The SQL aggregate function that gives the total of all values for a selected attribute in a given column is ____.a. COUNT b. MIN c. MAXd. SUM
Q:
The SQL aggregate function that gives the number of rows containing non-null values for the given column is ____.a. COUNT b. MIN c. MAXd. SUM
Q:
Which query is used to list a unique value for V_CODE, where the list will produce only a list of those values that are different from one another?
a. SELECT ONLY V_CODE FROM PRODUCT;
b. SELECT UNIQUE V_CODE FROM PRODUCT;
c. SELECT DIFFERENT V_CODE FROM PRODUCT;
d. SELECT DISTINCT V_CODE FROM PRODUCT;
Q:
The SQL query to output the contents of the EMPLOYEE table sorted by last name, first name, and initial is ____.
a. SELECT EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_AREACODE, EMP_PHONE FROM EMPLOYEE LIST BY EMP_LNAME, EMP_FNAME, EMP_INITIAL;
b. SELECT EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_AREACODE, EMP_PHONE FROM EMPLOYEE ORDER BY EMP_LNAME, EMP_FNAME, EMP_INITIAL;
c. SELECT EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_AREACODE, EMP_PHONE FROM EMPLOYEE DISPLAY BY EMP_LNAME, EMP_FNAME, EMP_INITIAL;
d. SELECT EMP_LNAME, EMP_FNAME, EMP_INITIAL, EMP_AREACODE, EMP_PHONE FROM EMPLOYEE SEQUENCE BY EMP_LNAME, EMP_FNAME, EMP_INITIAL;
Q:
The query used to list the P_CODE, P_DESCRIPT, P_INDATE, and P_PRICE fields from the PRODUCT table in ascending order by P_PRICE is ____.
a. SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE FROM PRODUCT SEQUENCE BY P_PRICE;
b. SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE FROM PRODUCT LIST BY P_PRICE;
c. SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE FROM PRODUCT ORDER BY P_PRICE;
d. SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE FROM PRODUCT ASCENDING BY P_PRICE;
Q:
A table can be deleted from the database by using the ____ command.a. DROP TABLE b. DELETE TABLE c. MODIFY TABLEd. ERASE TABLE
Q:
The ____ command is used with the ALTER TABLE command to modify the table by deleting a column.a. DROP b. REMOVE c. DELETEd. ERASE
Q:
The special operator used to check whether a subquery returns any rows is ____.a. BETWEEN b. EXISTS c. LIKEd. IN
Q:
The special operator used to check for similar character strings is ____.a. BETWEEN b. IS NULL c. LIKEd. IN
Q:
The ____ special operator is used to check whether an attribute value is null.a. BETWEEN b. IS NULL c. LIKEd. IN
Q:
The special operator used to check whether an attribute value is within a range of values is ____.a. BETWEEN b. NULL c. LIKEd. IN
Q:
Which query uses the correct SQL syntax to list the table contents for either V_CODE = 21344 or V_CODE = 24288?
a. SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE FROM PRODUCT WHERE V_CODE = 21344 OR V_CODE <= 24288
b. SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE FROM PRODUCT WHERE V_CODE = 21344 OR V_CODE => 24288
c. SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE FROM PRODUCT WHERE V_CODE = 21344 OR V_CODE > 24288
d. SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE FROM PRODUCT WHERE V_CODE = 21344 OR V_CODE = 24288
Q:
Which query will use the given columns and column aliases from the PRODUCT table to determine the total value of inventory held on hand and display the results in a column labeled TOTVALUE?
a. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH*P_PRICE AS TOTVALUE FROM PRODUCT;
b. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH=P_PRICE AS TOTVALUE FROM PRODUCT;
c. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH/P_PRICE AS TOTVALUE FROM PRODUCT;
d. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH-P_PRICE AS TOTVALUE FROM PRODUCT;
Q:
A(n) ____ is an alternate name given to a column or table in any SQL statement.a. alias b. data type c. stored functiond. trigger
Q:
Which query will use the given columns and column aliases from the PRODUCT table to determine the total value of inventory held on hand?
a. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH/P_PRICE FROM PRODUCT;
b. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH=P_PRICE FROM PRODUCT;
c. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH*P_PRICE FROM PRODUCT;
d. SELECT P_DESCRIPT, P_QOH, P_PRICE, P_QOH-P_PRICE FROM PRODUCT;
Q:
Which query will list all the rows in which the inventory stock dates occur on or after January 20, 2010?
a. SELECT P_DESCRIPT, P_QOH, P_MIN, P_PRICE, P_INDATE FROM PRODUCT WHERE P_INDATE >= '20-JAN-2010'
b. SELECT P_DESCRIPT, P_QOH, P_MIN, P_PRICE, P_INDATE FROM PRODUCT WHERE P_INDATE >= $20-JAN-2010$
c. SELECT P_DESCRIPT, P_QOH, P_MIN, P_PRICE, P_INDATE FROM PRODUCT WHERE P_INDATE <= '20-JAN-2010'
d. SELECT P_DESCRIPT, P_QOH, P_MIN, P_PRICE, P_INDATE FROM PRODUCT WHERE P_INDATE >= {20-JAN-2010}