Database Lab_Ch3_Quiz

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

Which of the following rules does not apply to column names in Oracle 12c ?

Column names can be up to 30 characters in length XXX

Which of the following symbols can be used in a column name?

# ??

Which of the following symbols cannot be used in a table name?

%

If a new table is being created based upon a subquery, the subquery must be enclosed in which of the following symbols?

()

When defining columns for a table in the CREATE TABLE command, the column list must be enclosed in which of the following symbols?

()

The maximum width of the NUMBER datatype is ___ DIGITS

38

The column definition of NUMBER(7, 4) indicates a precision of

7

What is the maximum width that can be assigned to a DATE column?

8 XXX

When modifying data in existing columns, which of the following is correct?

A column must be as wide as the data it already contains.

If you are creating a new table from data contained in an existing table, new column names can be specified by including a list of column names

Before the AS clause

Once a column has been set as UNUSED, which of the following is correct?

It is unavailable and will not be displayed in the table structure.

Which of the following keywords can be used to change the size, datatype, and/or default value of an existing column

MODIFY

Which of the following is a valid table name?

MYTABLE

Which of the following is a valid column name?

NEW_COLUMN

Which of the following commands will change the name of the LASTNAME column to LAST_NAME in the CUSTOMERS table?

NONE OF THE ABOVE

Which of the following rules apply to table names in Oracle 12c ?

Names can contain a number sign (#)

Which of the following commands can be used to make structural changes to an existing table?

ALTER TABLE

Which of the following commands will increase the size of the CITY column in the CUSTOMERS table from 12 to 20 and increase size of the LASTNAME column from 10 to 14?

ALTER TABLE customers MODIFY (city VARCHAR2(20), lastname VARCHAR2(14));

If the MAXRETAIL column of the PROMOTION table has been set as unused, which of the following commands is valid?

ALTER TABLE promotion DROP COLUMN maxretail; ALTER TABLE promotion DROP UNUSED COLUMNS;

Which of the following commands will set the MINRETAIL column of the PROMOTION table as unused?

ALTER TABLE promotion SET UNUSED (minretail); ALTER TABLE promotion SET UNUSED COLUMN minretail;

Which of the following commands will drop any columns marked as unused from the TABLEA table?

ALTER TABLE tablea DROP UNUSED COLUMNS;

Which of the following keywords cannot be used to modify an existing table?

ALTER TABLE....AS

Which of the following keywords is used to mark a column for deletion at a later time?

ALTER TABLE...SET UNUSED

Which of the following commands will add a new column named FIRSTORDERDATE to the CUSTOMERS table to store the date that the customer first placed an order with the company?

CREATE COLUMN firstorderdate, DATE TO customers; XXXXX

Which of the following keywords uses a subquery to create a new table using existing database tables?

CREATE TABLE .... AS

Which command instructs Oracle 12c to create a new table from existing data?

CREATE TABLE ....AS

Which of the following is a valid SQL statement?

CREATE TABLE newname (colA DATE, colB VARCHAR2(3);

A(n) ____ simply identifies the type of data that Oracle 12c will be expected to store in a column.

DATATYPE

Which of the following SQL*Plus commands will display the structure of a table?

DESC

Which of the following commands will display the structure of the CUSTOMERS table?

DESC CUSTOMERS XXXXX

Which of the following keywords is used to remove a database table in Oracle 12c ?

DROP TABLE

Which keywords are used to complete the deletion of a column previously marked with SET UNUSED?

DROP UNUSED COLUMNS

Which of the following commands will change the name of the PROMOTION table to GIFT?

RENAME promotion TO gift;

Which command is used to rename a table you own?

RENAME...TO

To delete all the rows in a table and free up the storage space that was occupied by those rows, the ____ command should be used

TRUCATE ROWS

If a column is defined as NUMBER(5,2), which of the following is true

The column can store a total of 5 digits, with 3 on the left side of the decimal point, and 2 on the right

When creating a table, which of the following statements is correct?

The column list must be enclosed in parentheses ( ).

When using the ALTER TABLE...DROP COLUMN command, which of the following is not correct?

The command can be used to delete multiple columns from a table.

Which of the following datatypes refers to fixed-length character data, where n represents the maximum length of the column?

VARCHAR(N)

Which of the following datatypes refers to variable-length character data, where n represents the maximum length of the column

VARCHAR2(N) XXX

Which of the following datatypes refers to variable-length character data, where n represents the maximum length of the column?

VARCHAR2(N) XXXX

Which of the following terms refers to commands that are used to create or modify database tables

data definition language (DDL)


Ensembles d'études connexes

Chapter 47: Caring for Clients with Disorders of the Liver, Gallbladder, or Pancreas

View Set

Chapter 62: Caring for Clients with Traumatic Musculoskeletal Injuries

View Set

Microeconomics Chapter 24: Monopoly

View Set

PEDs Chapt 4 Growth and Development of the Toddler

View Set

Abnormal Psychology Pract. Ch. 16

View Set

Chapter 5: Cultural Diversity PrepU

View Set