messages
listlengths
3
3
system
stringclasses
1 value
user
stringlengths
326
8.38k
assistant
stringlengths
18
577
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM manufacturers WHERE revenue > (SELECT avg(revenue) FROM manufacturers)
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM manufacturers WHERE revenue > (SELECT avg(revenue) FROM manufacturers)
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM manufacturers WHERE revenue < (SELECT min(revenue) FROM manufacturers WHERE headquarter = 'Austin')
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM manufacturers WHERE revenue < (SELECT min(revenue) FROM manufacturers WHERE headquarter = 'Austin')
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT sum(revenue) FROM manufacturers WHERE revenue > (SELECT min(revenue) FROM manufacturers WHERE headquarter = 'Austin')
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT sum(revenue) FROM manufacturers WHERE revenue > (SELECT min(revenue) FROM manufacturers WHERE headquarter = 'Austin')
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT sum(revenue) , founder FROM manufacturers GROUP BY founder
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT sum(revenue) , founder FROM manufacturers GROUP BY founder
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , max(revenue) , Headquarter FROM manufacturers GROUP BY Headquarter
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , max(revenue) , Headquarter FROM manufacturers GROUP BY Headquarter
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT sum(revenue) , name FROM manufacturers GROUP BY name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT sum(revenue) , name FROM manufacturers GROUP BY name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(T1.price) , T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(T1.price) , T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(DISTINCT T1.name) , T2.Headquarter FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code GROUP BY T2.Headquarter
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(DISTINCT T1.name) , T2.Headquarter FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code GROUP BY T2.Headquarter
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(DISTINCT name) FROM products WHERE name NOT IN (SELECT T1.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code WHERE T2.name = 'Sony')
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(DISTINCT name) FROM products WHERE name NOT IN (SELECT T1.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code WHERE T2.name = 'Sony')
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM manufacturers EXCEPT SELECT T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code WHERE T1.name = 'DVD drive'
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM manufacturers EXCEPT SELECT T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code WHERE T1.name = 'DVD drive'
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(*) , T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(*) , T2.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT Name FROM Products
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT Name FROM Products
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , price FROM products
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , price FROM products
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM products WHERE price <= 200
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name FROM products WHERE price <= 200
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT * FROM products WHERE price BETWEEN 60 AND 120
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT * FROM products WHERE price BETWEEN 60 AND 120
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(price) FROM products
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(price) FROM products
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(price) FROM products WHERE Manufacturer = 2
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(price) FROM products WHERE Manufacturer = 2
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(*) FROM products WHERE price >= 180
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT count(*) FROM products WHERE price >= 180
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , price FROM products WHERE price >= 180 ORDER BY price DESC , name ASC
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , price FROM products WHERE price >= 180 ORDER BY price DESC , name ASC
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT * FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT * FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT AVG(Price) , Manufacturer FROM Products GROUP BY Manufacturer
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT AVG(Price) , Manufacturer FROM Products GROUP BY Manufacturer
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(T1.Price) , T2.name FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(T1.Price) , T2.name FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(T1.Price) , T2.name FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name HAVING avg(T1.price) >= 150
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT avg(T1.Price) , T2.name FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name HAVING avg(T1.price) >= 150
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , price FROM Products ORDER BY price ASC LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT name , price FROM Products ORDER BY price ASC LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT T1.Name , max(T1.Price) , T2.name FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT T1.Name , max(T1.Price) , T2.name FROM products AS T1 JOIN Manufacturers AS T2 ON T1.manufacturer = T2.code GROUP BY T2.name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT code , name , min(price) FROM products GROUP BY name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE Manufacturers (\n Code INTEGER,\n Name VARCHAR...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE Manufacturers ( Code INTEGER, Name VARCHAR(255) NOT NULL, Headquarter VARCHAR(255) NOT NULL, Founder VARCHAR(255) NOT NULL, Revenue REAL, PRIMARY KEY (Code) ) CREATE TABLE Products ( Code INTEGER, Name VARCHAR(255) NOT NULL , Price DECIMAL NOT NULL , Manufacturer...
SELECT code , name , min(price) FROM products GROUP BY name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id FROM problem_log ORDER BY log_entry_date DESC LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id FROM problem_log ORDER BY log_entry_date DESC LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id , problem_id FROM problem_log ORDER BY log_entry_date LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id , problem_id FROM problem_log ORDER BY log_entry_date LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id , log_entry_date FROM problem_log WHERE problem_id = 10
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id , log_entry_date FROM problem_log WHERE problem_id = 10
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id , log_entry_description FROM problem_log
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_log_id , log_entry_description FROM problem_log
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT staff_first_name , staff_last_name FROM staff AS T1 JOIN problem_log AS T2 ON T1.staff_id = T2.assigned_to_staff_id WHERE T2.problem_id = 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT staff_first_name , staff_last_name FROM staff AS T1 JOIN problem_log AS T2 ON T1.staff_id = T2.assigned_to_staff_id WHERE T2.problem_id = 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT T2.problem_id , T2.problem_log_id FROM staff AS T1 JOIN problem_log AS T2 ON T1.staff_id = T2.assigned_to_staff_id WHERE T1.staff_first_name = "Rylan" AND T1.staff_last_name = "Homenick"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT T2.problem_id , T2.problem_log_id FROM staff AS T1 JOIN problem_log AS T2 ON T1.staff_id = T2.assigned_to_staff_id WHERE T1.staff_first_name = "Rylan" AND T1.staff_last_name = "Homenick"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) FROM product AS T1 JOIN problems AS T2 ON T1.product_id = T2.product_id WHERE T1.product_name = "voluptatem"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) FROM product AS T1 JOIN problems AS T2 ON T1.product_id = T2.product_id WHERE T1.product_name = "voluptatem"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) , T1.product_name FROM product AS T1 JOIN problems AS T2 ON T1.product_id = T2.product_id GROUP BY T1.product_name ORDER BY count(*) DESC LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) , T1.product_name FROM product AS T1 JOIN problems AS T2 ON T1.product_id = T2.product_id GROUP BY T1.product_name ORDER BY count(*) DESC LIMIT 1
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_description FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Christop"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_description FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Christop"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_last_name = "Bosco"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_last_name = "Bosco"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_id FROM problems WHERE date_problem_reported > "1978-06-26"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_id FROM problems WHERE date_problem_reported > "1978-06-26"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_id FROM problems WHERE date_problem_reported < "1978-06-26"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT problem_id FROM problems WHERE date_problem_reported < "1978-06-26"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) , T2.product_id FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id GROUP BY T2.product_id
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) , T2.product_id FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id GROUP BY T2.product_id
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) , T2.product_id FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id WHERE T1.date_problem_reported > "1986-11-13" GROUP BY T2.product_id
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT count(*) , T2.product_id FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id WHERE T1.date_problem_reported > "1986-11-13" GROUP BY T2.product_id
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT product_name FROM product ORDER BY product_name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT product_name FROM product ORDER BY product_name
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT product_name FROM product ORDER BY product_id
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT DISTINCT product_name FROM product ORDER BY product_id
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Dameon" AND T2.staff_last_name = "Frami" UNION SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Jolie" AND T2.staff_las...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Dameon" AND T2.staff_last_name = "Frami" UNION SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Jolie" AND T2.staff_las...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Christop" AND T2.staff_last_name = "Berge" INTERSECT SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.closure_authorised_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Ashley"...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Christop" AND T2.staff_last_name = "Berge" INTERSECT SELECT product_id FROM problems AS T1 JOIN staff AS T2 ON T1.closure_authorised_by_staff_id = T2.staff_id WHERE T2.staff_first_name = "Ashley"...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE date_problem_reported < ( SELECT min(date_problem_reported) FROM problems AS T3 JOIN staff AS T4 ON T3.reported_by_staff_id = T4.staff_id WHERE T4.staff_first_name = "Lysanne" AND T4.staff_last_name = "Turcotte" )
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE date_problem_reported < ( SELECT min(date_problem_reported) FROM problems AS T3 JOIN staff AS T4 ON T3.reported_by_staff_id = T4.staff_id WHERE T4.staff_first_name = "Lysanne" AND T4.staff_last_name = "Turcotte" )
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE date_problem_reported > ( SELECT max(date_problem_reported) FROM problems AS T3 JOIN staff AS T4 ON T3.reported_by_staff_id = T4.staff_id WHERE T4.staff_first_name = "Rylan" AND T4.staff_last_name = "Homenick" )
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE date_problem_reported > ( SELECT max(date_problem_reported) FROM problems AS T3 JOIN staff AS T4 ON T3.reported_by_staff_id = T4.staff_id WHERE T4.staff_first_name = "Rylan" AND T4.staff_last_name = "Homenick" )
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T2.product_name FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id GROUP BY T2.product_name ORDER BY count(*) DESC LIMIT 3
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T2.product_name FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id GROUP BY T2.product_name ORDER BY count(*) DESC LIMIT 3
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id WHERE T2.product_name = "voluptatem" AND T1.date_problem_reported > "1995"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T1.problem_id FROM problems AS T1 JOIN product AS T2 ON T1.product_id = T2.product_id WHERE T2.product_name = "voluptatem" AND T1.date_problem_reported > "1995"
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T3.staff_first_name , T3.staff_last_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T3 ON T1.product_id = T2.product_id AND T1.reported_by_staff_id = T3.staff_id WHERE T2.product_name = "rem" EXCEPT SELECT T3.staff_first_name , T3.staff_last_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T3.staff_first_name , T3.staff_last_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T3 ON T1.product_id = T2.product_id AND T1.reported_by_staff_id = T3.staff_id WHERE T2.product_name = "rem" EXCEPT SELECT T3.staff_first_name , T3.staff_last_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T2.product_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T3 ON T1.product_id = T2.product_id AND T1.reported_by_staff_id = T3.staff_id WHERE T3.staff_first_name = "Lacey" AND T3.staff_last_name = "Bosco" INTERSECT SELECT T2.product_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T3 ON T1.pr...
[ { "role": "system", "content": "You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation." }, { "role": "user", "content": "### Database Schema\nCREATE TABLE `Problem_Category_Codes` (\n`problem_category_co...
You are an expert SQL assistant. Given a database schema and a question, generate the correct SQL query. Output only the SQL query, no explanation.
### Database Schema CREATE TABLE `Problem_Category_Codes` ( `problem_category_code` VARCHAR(20) PRIMARY KEY, `problem_category_description` VARCHAR(80) ) CREATE TABLE `Problem_Log` ( `problem_log_id` INTEGER PRIMARY KEY, `assigned_to_staff_id` INTEGER NOT NULL, `problem_id` INTEGER NOT NULL, `problem_category_code` VA...
SELECT T2.product_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T3 ON T1.product_id = T2.product_id AND T1.reported_by_staff_id = T3.staff_id WHERE T3.staff_first_name = "Lacey" AND T3.staff_last_name = "Bosco" INTERSECT SELECT T2.product_name FROM problems AS T1 JOIN product AS T2 JOIN staff AS T3 ON T1.pr...