Recyclable and Low Fat Products
<p>Table: <code>Products</code></p>

<pre>
+-------------+---------+
| Column Name | Type    |
+-------------+---------+
| product_id  | int     |
| low_fats    | enum    |
| recyclable  | enum    |
+-------------+---------+
product_id is the primary key (column with unique values) for this table.
low_fats is an ENUM (category) of type (&#39;Y&#39;, &#39;N&#39;) where &#39;Y&#39; means this product is low fat and &#39;N&#39; means it is not.
recyclable is an ENUM (category) of types (&#39;Y&#39;, &#39;N&#39;) where &#39;Y&#39; means this product is recyclable and &#39;N&#39; means it is not.</pre>

<p>&nbsp;</p>

<p>Write a solution to find the ids of products that are both low fat and recyclable.</p>

<p>Return the result table in <strong>any order</strong>.</p>

<p>The result format is in the following example.</p>

<p>&nbsp;</p>
<p><strong class="example">Example 1:</strong></p>

<pre>
<strong>Input:</strong> 
Products table:
+-------------+----------+------------+
| product_id  | low_fats | recyclable |
+-------------+----------+------------+
| 0           | Y        | N          |
| 1           | Y        | Y          |
| 2           | N        | Y          |
| 3           | Y        | Y          |
| 4           | N        | N          |
+-------------+----------+------------+
<strong>Output:</strong> 
+-------------+
| product_id  |
+-------------+
| 1           |
| 3           |
+-------------+
<strong>Explanation:</strong> Only products 1 and 3 are both low fat and recyclable.
</pre>

[]
["Create table If Not Exists Products (product_id int, low_fats ENUM('Y', 'N'), recyclable ENUM('Y','N'))", 'Truncate table Products', "insert into Products (product_id, low_fats, recyclable) values ('0', 'Y', 'N')", "insert into Products (product_id, low_fats, recyclable) values ('1', 'Y', 'Y')", "insert into Products (product_id, low_fats, recyclable) values ('2', 'N', 'Y')", "insert into Products (product_id, low_fats, recyclable) values ('3', 'Y', 'Y')", "insert into Products (product_id, low_fats, recyclable) values ('4', 'N', 'N')"]
[{"value": "mysql", "text": "MySQL", "defaultCode": "# Write your MySQL query statement below\n"}, {"value": "mssql", "text": "MS SQL Server", "defaultCode": "/* Write your T-SQL query statement below */\n"}, {"value": "oraclesql", "text": "Oracle", "defaultCode": "/* Write your PL/SQL query statement below */\n"}, {"value": "pythondata", "text": "Pandas", "defaultCode": "import pandas as pd\n\ndef find_products(products: pd.DataFrame) -> pd.DataFrame:\n    "}, {"value": "postgresql", "text": "PostgreSQL", "defaultCode": "-- Write your PostgreSQL query statement below\n"}]
{"mysql": ["Create table If Not Exists Products (product_id int, low_fats ENUM('Y', 'N'), recyclable ENUM('Y','N'))"], "mssql": ["Create table Products (product_id int, low_fats varchar(1) not null check(low_fats in ('Y', 'N')), recyclable varchar(1) not null check(recyclable in ('Y', 'N')))"], "oraclesql": ["Create table Products (product_id int, low_fats varchar(1) not null check(low_fats in ('Y', 'N')), recyclable varchar(1) not null check(recyclable in ('Y', 'N')))"], "database": true, "name": "find_products", "pythondata": ["Products = pd.DataFrame([], columns=['product_id', 'low_fats', 'recyclable']).astype({'product_id':'int64', 'low_fats':'category', 'recyclable':'category'})"], "postgresql": ["Create table If Not Exists Products (product_id int, low_fats VARCHAR(30) CHECK (low_fats IN ('Y', 'N')), recyclable VARCHAR(30) CHECK (recyclable IN ('Y','N')))\n"], "database_schema": {"Products": {"product_id": "INT", "low_fats": "ENUM('Y', 'N')", "recyclable": "ENUM('Y', 'N')"}}}
{"mysql": ["MySQL", "<p><code>MySQL 8.0</code>.</p>"], "mssql": ["MS SQL Server", "<p><code>mssql server 2019</code>.</p>"], "oraclesql": ["Oracle", "<p><code>Oracle Sql 11.2</code>.</p>"], "pythondata": ["Pandas", "<p>Python 3.10 with Pandas 2.2.2 and NumPy 1.26.4</p>"], "postgresql": ["PostgreSQL", "<p>PostgreSQL 16</p>"]}
['Database']