Practice Test 3 Flashcards

1
Q

Combines two tables into one result (Includes all columns and all combinations of rows from both tables)

A

Product

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

Selects one or more columns from a table

A

Project

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

Provides all possible combinations of rows from both tables

A

Cross Join

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

Combines the results of two queries into a single result set

A

Union

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

Why are alias needed in self join

A

To be able to differentiate between the two outputted tables

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

What is used as a wildcard to represent any character

A

%

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

Aggregates rows that have the same values in a specified column

A

Group By

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

This filters rows after adding a Group By operand

A

HAVING

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

Filters and removes duplicate rows

A

DISTINCT

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

How would you add a new Column to table

A

ALTER TABLE ADD

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

How do you rename a Column

A

ALTER TAABLE CHANGE

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

Ends the current transaction and makes all changes permanent

A

COMMIT

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

Undo changes made in a current transaction

A

ROLLBACK

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

How do you create an index on a column

A

CREATE INDEX

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

How do you add a constraint to a table

A

ALTER TABLE ADD CONSTRAINT

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

How do you remove a constraint from a table

A

ALTER TABLE DROP CONSTRAINT

17
Q

SQL Keyword to specifies a foreign key

A

FOREIGN KEY

18
Q

What does CREATE VIEW do?

A

Creates a virtual table based on the result set of a select query

19
Q

Bridge or Junction table

A

Used in a many-to-many relationship to resolve them into two 1-M

20
Q

Removes partial dependencies

A

2NF or second normal form

21
Q

BOYCE-CODD normal form

A

Eliminates all common redundancy and considered the gold standard

22
Q

3NF

A

Dependent on the entire primary key and nothing but the key

23
Q

Entity type Means

24
Q

A unique Clustered Index is auto made when….

A

A primary key is created