LESSON 6 Flashcards

1
Q

Joins allow the retrieval of related data spread across multiple tables in a relational database

A

Combine Data from Multiple Tables

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

Joins enable complex queries that
consolidate information for reporting and analytics

A

Support Advanced Data Analysis

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

Joins leverage primary and foreign key relationships to link rows in one table to corresponding rows in another.

A

Establish Relationships Between
Tables

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

By retrieving only, the required data from multiple tables, JOIN operations reduce redundancy and improve query performance.

A

Optimize Query Efficiency

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

Different types of JOINs (INNER, LEFT, RIGHT, FULL OUTER, CROSS) provide flexibility in fetching data depending on the analysis needs

A

Allow Versatile Data Retrieval

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

Different types of JOINs

A

INNER, LEFT, RIGHT, FULL OUTER, CROSS

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

By linking related tables, JOINs help maintain normalized database structures without duplicating data.

A

Enhance Data Integrity

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

JOINs mimic real-world connections between entities, making it easier to model and query practical relationships.

A

Facilitate Real-World Scenarios

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

is used to combine rows from two or more tables, based on a related column between them.

A

JOIN clause

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

Returns records that have matching values in both tables

A

INNER JOIN

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

Returns all records from the left table, and the matched records from the right table

A

LEFT JOIN:

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

Returns all records from the right table, and the matched records from the left table

A

RIGHT JOIN

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

Returns all records from both tables

A

CROSS JOIN

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

return rows when there is at least one match in both tables

A

Inner Join

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

does not require each record in the two joined tables to have a matching record

A

Outer Join

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

Outer Join is subdivided into:

A

Left join, Right Join, Full Join

9
Q

returns all rows from the left table (or the first table), even if there are no matches in the right table

A

Left Join

10
Q

both tables are secondary (or optional), such that if rows are being matched in table A and table B, then all rows from table A are displayed even if there is no matching row in table B, and vice versa

A

Full Join

10
Q

returns all the rows from the right table (or the second table), even if there are no matches in the left table

A

Right Join

10
Q

is a keyword that enables users to create new views

A

CREATE VIEW

11
Q

Syntax of creating views

A

CREATE VIEW ViewName AS SELECT statement

12
Q

BENEFITS OF VIEWS

A

reduce complexity

13
Q

is the keyword used to modify a created view

A

ALTER VIEW

14
Q

ALTER VIEW syntax:

A

ALTER VIEW ViewName AS SELECT statement