Test 2 Notes Flashcards

1
Q

When converting an entity diagram into a relational schema, rule 1 states that….

A

Every entity is converted into a table.

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

When converting an entity diagram into a relational schema, rule 2 states that….

A

All relationships are represented by placing foreign keys into tables.

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

In the tables the identifiers become…….. and the attributes become ……..

A
  1. Primary Keys
  2. Columns
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

In a 1:1 relationship where do you place the foreign key?

A

The foreign Key can be placed in one table or the other.

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

In a 1:N relationship where do you place the foreign key?

A

The foreign key must be placed into the N(Child) side of the relationship.

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

When converting a N:M relationship what must you do?

A

You must make a new intersection table.

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

In SQL the CREATE key does what?

A

Creates objects.

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

In SQL the ALTER key does what?

A

Modifies objects.

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

In SQL the DROP key does what?

A

Deletes objects.

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

In SQL the TRUNCATE key does what?

A

Deletes table data.

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

In SQL the INT key holds what?

A

Whole Numbers.

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

In SQL the VARChar() key holds what?

A

Strings

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

In SQL the CONSTRAINT key does what?

A

Adds attributes, and creates composite, foreign, and primary keys.

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

In SQL the INSERT key does what?

A

Adds new data

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

Which Element follows after the SELECT keyword?

A

Column

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

Which Element follows after the FROM keyword?

A

Tables

17
Q

Which Element follows after the WHERE keyword?

A

Criteria/Filter

18
Q

Which symbol in SQL shows all of the column values or items?

A

The asterisk (*) symbol.

19
Q

What SQL key cuts off output?

A

LIMIT

20
Q

What SQL key duplicates elements?

A

DISTINCT

21
Q

What SQL key carries DELETE or UPDATE actions on the primary key to matching foreign keys?

A

CASCADE

22
Q

What symbol represents the not equals in SQL?

A

<>

23
Q

The AND symbol shows what between data sets?

A

Intersection

24
Q

The OR symbol shows what between data sets?

A

Union

25
Q

WHAT SQL keyword filters from a list of items.

A

IN

26
Q

What SQL keyword negates information.

A

NOT

27
Q

What SQL keyword sorts results?

A

ORDER BY

28
Q

What do Wild Cards do in SQL?

A

They create patters that need to be matched.

29
Q

What wild card symbol creates any string of any length?

A

The percent (%) symbol

30
Q

What wild card symbol matches one single character?

A

The underscore (_) symbol

31
Q

The LIKE keyword does what?

A

Searches partial data values.

32
Q

List built in functions in SQL

A

COUNT
MIN
MAX
SUM
AVG

33
Q

In a Joins Query what is the GOOD method?

A

Natural Join

34
Q

In a Joins Query what is the BETTER method?

A

Join On

35
Q

In a Joins Query what is the BEST method

A

Join Using