MySQL Tutorial Point – We would love to share with you how to use MySQL JOINS with example. Basically MySQL Provide following types of Join INNER JOIN, LEFT JOIN, RIGHT JOIN & SELF JOIN.

In this blog post we will discuss about What is MySQL join? Type of Joins etc

Here are the different types of the JOINs in SQL:

  • INNER JOIN: Returns records that have matching values in both tables
  • LEFT JOIN: Returns all records from the left table, and the matched records from the right table
  • RIGHT JOIN: Returns all records from the right table, and the matched records from the left table
  • FULL JOIN: Returns all records when there is a match in either left or right table
  • CROSS JOIN: This join produces a result where the number of rows in the first table gets multiplied with the rows in the second table.
  • SELF JOIN: Self-join is a regular join and here the table joins with itself only.

MySQL Joins

JOINS can be used in MySQL with the Select Statement. It is used to get data from two or more database tables. When we want to get the records from two or more database tables, then we need to use MySQL JOINS at that time. The tables are mutually related using primary and foreign keys.

INNER JOIN MySQL

In MySQL INNER JOIN clause selects records if the given column values matching in both tables. MySQL INNER JOIN is used to fetch data from multiple tables.

#mysql

MySQL Joins, MySQL INNER, LEFT, RIGHT Joins For Beginners - W3path
2.30 GEEK