Chapter 11 Study Questions Flashcards
The ____________ statement consists of the name of a new table, followed by the names, and data types of its columns.
create table
___________ are used to enforce integrity of the data in a table by defining rules about the values that can be stored in the columns of the table.
constraints
A(n) ___________________ is coded as part of the definition of a column it constrains.
column-level constraint
A(n) _________________ is coded as if it is a separate column definition, and the columns it constrains are named within that definition.
table-level constraint
A(n) ___________________ prevents null values from being stored in a column.
not null constraint
A(n) ___________ requires that each row has a unique value in the column but allows null values to be stored in the column or columns for the primary key and it does not allow null values.
unique constraint
A(n) __________________ requires values in one table to match values in another table.
foreign key constraint
A(n) __________________ is used to define the relationships between tables and enforce referential integrity.
foreign key constraint
With a(n) _________________ when a row is deleted from the primary key table, rows are automatically deleted from the foreign key table.
on delete cascade
The _________ statement may be used to add, drop, or modify the columns of an existing table.
alter table
The ___________ statement can be used to change the name of an existing table.
rename table
Tot remove a table from the current database, issue a ___________ statement.
drop table
The ______________ statement can be used to delete all data from a table.
truncate table
A(n) _____ speeds up joins and searches by providing a way to go directly to a row rather than having a script.
index
A(n) ______ is a file that contains one or more SQL statements.
script