<aside> 💡

Project Overview:

This project identifies products that are both low fat and recyclable. The solution demonstrates SQL filtering techniques with categorical data using the WHERE clause.

</aside>


Problem Description:

Table: Products

The task is to retrieve the product_id of products where:


Solution:

The query filters the Products table for rows where both low_fats and recyclable are 'Y'.

SELECT
    product_id
FROM
    Products
WHERE
    low_fats = 'Y'
    AND recyclable = 'Y';


Explanation:

  1. Filtering Conditions:
  2. Selecting Columns:

Example Input and Output: