5. Database Questions Flashcards
1
Q
What’s an inner join?
A
An inner join selects records that have matching values from two given tables.
syntax:
SELECT column_name(s)
FROM table1
INNER JOIN table2 ON table1.column_name = table2.column_name;
2
Q
What is a left join?
A
A left join selects all the records from the left table but only the matching records from the right table.
3
Q
What is a right join?
A
A right join selects all the records from the right table but only the matching records from the left table.
4
Q
What is a full outer join?
A
It selects all records from both of the two given tables.
5
Q
What is a stored procedure?
A
A subroutine with SQL statements an application uses to communicate with a database efficiently.