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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T2.balance + T3.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid WHERE T3.balance > (SELECT avg(balance) FROM savings)
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T2.balance + T3.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid WHERE T3.balance > (SELECT avg(balance) FROM savings)
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T2.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T3.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T2.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T3.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT count(*) , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid GROUP BY T1.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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT count(*) , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid GROUP BY T1.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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT sum(T2.balance) , T1.name FROM accounts AS T1 JOIN savings AS T2 ON T1.custid = T2.custid GROUP BY T1.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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT sum(T2.balance) , T1.name FROM accounts AS T1 JOIN savings AS T2 ON T1.custid = T2.custid GROUP BY T1.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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid WHERE T2.balance < (SELECT avg(balance) FROM checking)
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid WHERE T2.balance < (SELECT avg(balance) FROM checking)
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T3.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T2.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T3.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T2.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.balance + T2.balance FROM checking AS T1 JOIN savings AS T2 ON T1.custid = T2.custid ORDER BY T1.balance + T2.balance
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.balance + T2.balance FROM checking AS T1 JOIN savings AS T2 ON T1.custid = T2.custid ORDER BY T1.balance + T2.balance
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T2.balance , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T3.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T2.balance , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T3.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T2.balance , T3.balance , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T2.balance , T3.balance , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T2.balance , T3.balance , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T2.balance + T3.balance DESC
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T2.balance , T3.balance , T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid ORDER BY T2.balance + T3.balance DESC
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid WHERE T2.balance > T3.balance
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid WHERE T2.balance > T3.balance
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T3.balance + T2.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid WHERE T3.balance < T2.balance
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T3.balance + T2.balance FROM accounts AS T1 JOIN checking AS T2 ON T1.custid = T2.custid JOIN savings AS T3 ON T1.custid = T3.custid WHERE T3.balance < T2.balance
[ { "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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T2.balance FROM accounts AS T1 JOIN savings AS T2 ON T1.custid = T2.custid ORDER BY T2.balance 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 ACCOUNTS (\n custid BIGINT NOT NULL...
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 ACCOUNTS ( custid BIGINT NOT NULL PRIMARY KEY, name VARCHAR(64) NOT NULL ) CREATE TABLE SAVINGS ( custid BIGINT NOT NULL PRIMARY KEY, balance FLOAT NOT NULL, FOREIGN KEY (custid) REFERENCES ACCOUNTS (custid) ) CREATE TABLE CH...
SELECT T1.name , T2.balance FROM accounts AS T1 JOIN savings AS T2 ON T1.custid = T2.custid ORDER BY T2.balance 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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT count(*) FROM browser WHERE market_share >= 5
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT name FROM browser ORDER BY market_share DESC
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT id , name , market_share FROM browser
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT max(market_share) , min(market_share) , avg(market_share) FROM browser
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT id , market_share FROM browser WHERE name = 'Safari'
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT name , operating_system FROM web_client_accelerator WHERE CONNECTION != 'Broadband'
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT T1.name FROM browser AS T1 JOIN accelerator_compatible_browser AS T2 ON T1.id = T2.browser_id JOIN web_client_accelerator AS T3 ON T2.accelerator_id = T3.id WHERE T3.name = 'CProxy' AND T2.compatible_since_year > 1998
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT T1.id , T1.Name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id = T1.id GROUP BY T1.id HAVING count(*) >= 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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT T1.id , T1.name FROM browser AS T1 JOIN accelerator_compatible_browser AS T2 ON T1.id = T2.browser_id GROUP BY T1.id 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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT T1.compatible_since_year FROM accelerator_compatible_browser AS T1 JOIN browser AS T2 ON T1.browser_id = T2.id JOIN web_client_accelerator AS T3 ON T1.accelerator_id = T3.id WHERE T3.name = 'CACHEbox' AND T2.name = 'Internet Explorer'
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT count(DISTINCT client) FROM web_client_accelerator
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT count(*) FROM web_client_accelerator WHERE id NOT IN ( SELECT accelerator_id FROM accelerator_compatible_browser );
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT DISTINCT T1.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id = T1.id JOIN browser AS T3 ON T2.browser_id = T3.id WHERE T3.market_share > 15;
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT T3.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id = T1.id JOIN browser AS T3 ON T2.browser_id = T3.id WHERE T1.name = 'CACHEbox' INTERSECT SELECT T3.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT name , operating_system FROM web_client_accelerator EXCEPT SELECT T1.name , T1.operating_system FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id = T1.id JOIN browser AS T3 ON T2.browser_id = T3.id WHERE T3.name = 'Opera'
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT name FROM web_client_accelerator WHERE name LIKE "%Opera%"
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT Operating_system , count(*) FROM web_client_accelerator GROUP BY Operating_system
[ { "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 \"Web_client_accelerator\" (\n\"id\" int,\n\"nam...
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 "Web_client_accelerator" ( "id" int, "name" text, "Operating_system" text, "Client" text, "Connection" text, primary key("id") ) CREATE TABLE "browser" ( "id" int, "name" text, "market_share" real, primary key("id") ) CREATE TABLE "accelerator_compatible_browser" ( "accelerator_id" in...
SELECT T2.name , T3.name FROM accelerator_compatible_browser AS T1 JOIN browser AS T2 ON T1.browser_id = T2.id JOIN web_client_accelerator AS T3 ON T1.accelerator_id = T3.id ORDER BY T1.compatible_since_year DESC
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT count(*) FROM wrestler
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT count(*) FROM wrestler
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler ORDER BY Days_held DESC
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler ORDER BY Days_held DESC
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler ORDER BY Days_held 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler ORDER BY Days_held 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT DISTINCT Reign FROM wrestler WHERE LOCATION != "Tokyo , Japan"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT DISTINCT Reign FROM wrestler WHERE LOCATION != "Tokyo , Japan"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name , LOCATION FROM wrestler
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name , LOCATION FROM wrestler
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Elimination_Move FROM Elimination WHERE Team = "Team Orton"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Elimination_Move FROM Elimination WHERE Team = "Team Orton"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T2.Name , T1.Elimination_Move FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T2.Name , T1.Elimination_Move FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T2.Name , T1.Team FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_ID ORDER BY T2.Days_held DESC
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T2.Name , T1.Team FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_ID ORDER BY T2.Days_held DESC
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_ID ORDER BY T2.Days_held 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_ID ORDER BY T2.Days_held 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_ID WHERE T2.Days_held > 50
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT T1.Time FROM elimination AS T1 JOIN wrestler AS T2 ON T1.Wrestler_ID = T2.Wrestler_ID WHERE T2.Days_held > 50
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Team , COUNT(*) FROM elimination GROUP BY Team
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Team , COUNT(*) FROM elimination GROUP BY Team
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Team FROM elimination GROUP BY Team HAVING COUNT(*) > 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Team FROM elimination GROUP BY Team HAVING COUNT(*) > 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Reign , Days_held FROM wrestler
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Reign , Days_held FROM wrestler
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler WHERE Days_held < 100
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler WHERE Days_held < 100
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Reign FROM wrestler GROUP BY Reign 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Reign FROM wrestler GROUP BY Reign 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT LOCATION FROM wrestler GROUP BY LOCATION HAVING COUNT(*) > 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT LOCATION FROM wrestler GROUP BY LOCATION HAVING COUNT(*) > 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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler WHERE Wrestler_ID NOT IN (SELECT Wrestler_ID FROM elimination)
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Name FROM wrestler WHERE Wrestler_ID NOT IN (SELECT Wrestler_ID FROM elimination)
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Team FROM Elimination WHERE Eliminated_By = "Orton" INTERSECT SELECT Team FROM Elimination WHERE Eliminated_By = "Benjamin"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT Team FROM Elimination WHERE Eliminated_By = "Orton" INTERSECT SELECT Team FROM Elimination WHERE Eliminated_By = "Benjamin"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT COUNT (DISTINCT team) FROM elimination
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT COUNT (DISTINCT team) FROM elimination
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT TIME FROM elimination WHERE Eliminated_By = "Punk" OR Eliminated_By = "Orton"
[ { "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 \"wrestler\" (\n\"Wrestler_ID\" int,\n\"Name\" t...
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 "wrestler" ( "Wrestler_ID" int, "Name" text, "Reign" text, "Days_held" text, "Location" text, "Event" text, PRIMARY KEY ("Wrestler_ID") ) CREATE TABLE "Elimination" ( "Elimination_ID" text, "Wrestler_ID" text, "Team" text, "Eliminated_By" text, "Elimination_Move" text, "Time" text, PRI...
SELECT TIME FROM elimination WHERE Eliminated_By = "Punk" OR Eliminated_By = "Orton"
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT count(*) FROM school
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT count(*) FROM school
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT school_name FROM school ORDER BY school_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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT school_name , LOCATION , mascot FROM school
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT sum(enrollment) , avg(enrollment) FROM school
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT mascot FROM school WHERE enrollment > (SELECT avg(enrollment) FROM school)
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT school_name FROM school ORDER BY enrollment 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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT avg(enrollment) , max(enrollment) , min(enrollment) FROM school
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT county , count(*) , sum(enrollment) FROM school GROUP BY county
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT count(DISTINCT T1.donator_name) FROM endowment AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id WHERE T2.school_name = "Glenn"
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT donator_name , sum(amount) FROM endowment GROUP BY donator_name ORDER BY sum(amount) DESC
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT school_name FROM school WHERE school_id NOT IN (SELECT school_id FROM endowment)
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT T2.school_name FROM endowment AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id GROUP BY T1.school_id HAVING sum(T1.amount) <= 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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT T1.donator_name FROM endowment AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id WHERE T2.school_name = 'Glenn' INTERSECT SELECT T1.donator_name FROM endowment AS T1 JOIN school AS T2 ON T1.school_id = T2.school_id WHERE T2.school_name = 'Triton'
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT donator_name FROM endowment EXCEPT SELECT donator_name FROM endowment WHERE amount < 9
[ { "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 \"School\" (\n\"School_id\" text,\n\"School_name...
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 "School" ( "School_id" text, "School_name" text, "Location" text, "Mascot" text, "Enrollment" int, "IHSAA_Class" text, "IHSAA_Football_Class" text, "County" text, PRIMARY KEY ("School_id") ) CREATE TABLE "budget" ( "School_id" int, "Year" int, "Budgeted" int, "total_budget_percent_budg...
SELECT amount , donator_name FROM endowment ORDER BY amount DESC LIMIT 1