Databases Flashcards

1
Q

What is normalistaion?

A

Every non key attribute is dependent on the key, the whole key, and nothing but the key

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What is 1st normal form?

A

No repeated attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What is 2nd normal form?

A

All attributes are dependent on the key

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is 3rd normal form?

A

No attribute must be dependent on any non key attribute

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Describe the SELECT function in SQL

A

SELECT
FROM
WHERE
ORDER BY

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Describe the INSERT function in DML

A

INSERT INTO table_name (column1, column2…)

VALUES (value1, value2)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Describe the UPDATE function in DML

A

UPDATE table_name
SET coulmn1 = value, column2 = value2….
WHERE some_column = some_value

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Describe the DELETE function in DML

A

DELETE FROM table_name

WHERE some_column = some_value

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

a) Describe the CREATE TABLE function in DDL

b) What are some datatypes that can be used in table creation?

A
CREATE TABLE 
(
field name 1   (datatype),
field name 2   (datatype),
field name 3   (datatype),
PRIMARY KEY (field name)
)

Varchar(x), int, yes/no, date, money

How well did you know this?
1
Not at all
2
3
4
5
Perfectly