• Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

Card Range To Study

through

image

Play button

image

Play button

image

Progress

1/12

Click to flip

Use LEFT and RIGHT arrow keys to navigate between flashcards;

Use UP and DOWN arrow keys to flip the card;

H to show hint;

A reads text to speech;

12 Cards in this Set

  • Front
  • Back
candidate key
for every table there is at least one column with the property than no two rows have the same combination of data values for these columns
What if a table has more than 1 candidate key
If there is more than one candidate key within a table the database designer designates one of them as the primary key of the table
The DDL contains three generic SQL statements
CREATE object
ALTER object
DROP object
This statements create, alter, and remove database objects (databases, tables, columns, indexes)
DML encompasses
all operations that manipulate the data.
SELECT - retrieval
INSERT - insertion
DELETE - deletion
UPDATE - updating
normalizaton (def)
process during which the existing tables of a database are tested to find certain dependencies between the columns of a table.If one of these generated tables till contains data dependencies, the process of normalization must be repeated until all dependencies are resolved.
functional dependencie )def_
means that by using the known value of one column, the corresponding value of another column can always be uniquely determined
Syntaxis to create table and set primary key (used for when we have a single column as primary key)
SQL Server

CREATE TABLE Persons
(
P_Id int NOT NULL PRIMARY KEY,
LastName varchar(255) NOT NULL,
FirstName varchar(255),
Address varchar(255),
City varchar(255)
)
Create a primary key on multiple columns when creating a table
CREATE TABLE Persons
(
P_Id int NOT NULL,
LastName varchar(255) NOT NULL,
FirstName varchar(255),
Address varchar(255),
City varchar(255),
CONSTRAINT pk_PersonID PRIMARY KEY (P_Id,LastName)
)
Normalization of data
Normalization of data is a process during which the existing tables of a database
are tested to find certain dependencies between the columns of a table. If such
dependencies exist, the table is restructured into multiple (usually two) tables, which
eliminates any column dependencies. If one of these generated tables still contains data
dependencies, the process of normalization must be repeated until all dependencies are
resolved.
First Normal Form
First normal form (1NF) means that a table has no multivalued attributes or composite
attributes. (A composite attribute contains other attributes and can therefore be divided
into smaller parts.) All relational tables are by definition in 1NF, because the value of
any column in a row must be atomic—that is, single valued
Second Normal Form
A table is in second normal form (2NF) if it is in 1NF and there is no nonkey column
dependent on a partial primary key of that table. This means if (A,B) is a combination
of two table columns building the key, then there is no column of the table depending
either on only A or only B.
Third Normal Form
A table is in third normal form (3NF) if it is in 2NF and there are no functional
dependencies between nonkey columns