Share
What is the difference between INNER JOIN and OUTER JOIN?
Question
can you help me with this question
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Answer ( 1 )
📌 Example:
-- INNER JOIN (Only common records)
SELECT employees.name, department.dept_name
FROM employees
INNER JOIN department ON employees.dept_id = department.dept_id;
-- LEFT JOIN (All employees, even those without a department)
SELECT employees.name, department.dept_name
FROM employees
LEFT JOIN department ON employees.dept_id = department.dept_id;