Customers Who Bought Products A and B but Not C
[]
['Create table If Not Exists Customers (customer_id int, customer_name varchar(30))', 'Create table If Not Exists Orders (order_id int, customer_id int, product_name varchar(30))', 'Truncate table Customers', "insert into Customers (customer_id, customer_name) values ('1', 'Daniel')", "insert into Customers (customer_id, customer_name) values ('2', 'Diana')", "insert into Customers (customer_id, customer_name) values ('3', 'Elizabeth')", "insert into Customers (customer_id, customer_name) values ('4', 'Jhon')", 'Truncate table Orders', "insert into Orders (order_id, customer_id, product_name) values ('10', '1', 'A')", "insert into Orders (order_id, customer_id, product_name) values ('20', '1', 'B')", "insert into Orders (order_id, customer_id, product_name) values ('30', '1', 'D')", "insert into Orders (order_id, customer_id, product_name) values ('40', '1', 'C')", "insert into Orders (order_id, customer_id, product_name) values ('50', '2', 'A')", "insert into Orders (order_id, customer_id, product_name) values ('60', '3', 'A')", "insert into Orders (order_id, customer_id, product_name) values ('70', '3', 'B')", "insert into Orders (order_id, customer_id, product_name) values ('80', '3', 'D')", "insert into Orders (order_id, customer_id, product_name) values ('90', '4', 'C')"]
{"mysql": ["Create table If Not Exists Customers (customer_id int, customer_name varchar(30))", "Create table If Not Exists Orders (order_id int, customer_id int, product_name varchar(30))"], "mssql": ["Create table Customers (customer_id int, customer_name varchar(30))", "Create table Orders (order_id int, customer_id int, product_name varchar(30))"], "oraclesql": ["Create table Customers (customer_id int, customer_name varchar(30))", "Create table Orders (order_id int, customer_id int, product_name varchar(30))"], "database": true, "name": "find_customers", "pythondata": ["Customers = pd.DataFrame([], columns=['customer_id', 'customer_name']).astype({'customer_id':'Int64', 'customer_name':'object'})", "Orders = pd.DataFrame([], columns=['order_id', 'customer_id', 'product_name']).astype({'order_id':'Int64', 'customer_id':'Int64', 'product_name':'object'})"], "postgresql": ["\nCreate table If Not Exists Customers (customer_id int, customer_name varchar(30))\n", "Create table If Not Exists Orders (order_id int, customer_id int, product_name varchar(30))"], "database_schema": {"Customers": {"customer_id": "INT", "customer_name": "VARCHAR(30)"}, "Orders": {"order_id": "INT", "customer_id": "INT", "product_name": "VARCHAR(30)"}}}
{"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']