You are tasked with creating a report that combines data from a "sales" table and a "products" table. The requirement is to list all products, even those that haven't made a sale. Which JOIN operation would you choose?
- LEFT JOIN
- INNER JOIN
- RIGHT JOIN
- FULL OUTER JOIN
A LEFT JOIN retrieves all rows from the left table (products) and the matching rows from the right table (sales). It includes products with no matching sales, meeting the requirement.
Loading...
Related Quiz
- You want to output a variable's value along with some text in PHP. How would you use echo or print to do this?
- What is the actually used PHP version?
- What keyword is used in PHP to access a global variable inside a function?
- In a switch-case structure, the ________ keyword is used to specify the default action when no case matches.
- In a PHP loop, break will ______ the loop, while continue will only skip the current iteration and proceed with the next one.