RIGHT JOIN

SQL RIGHT JOIN Keyword

The RIGHT JOIN command returns all rows from the right table and the matching rows from the left table. If there is no match, the result from the left table will show as NULL.

Tutorials dojo strip

SQL RIGHT JOIN Syntax

SQL

SQL RIGHT JOIN Doctors and Appointments Example

This query selects all doctors and any appointments they may have scheduled.

SQL

Note: This code does not work in the TechKubo playground. SQLite (and the TechKubo playground) does not support RIGHT JOIN. You can achieve similar results using LEFT JOIN by reversing the table order.

SQL RIGHT JOIN Labs

Tutorials dojo strip