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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_ID FROM Employees WHERE employee_name = "Ebba" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_ID FROM Employees WHERE employee_name = "Ebba" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_name FROM Employees WHERE role_code = "HR" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_name FROM Employees WHERE role_code = "HR" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code , count(*) FROM Employees GROUP BY role_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code , count(*) FROM Employees GROUP BY role_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code FROM Employees GROUP BY role_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code FROM Employees GROUP BY role_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code FROM Employees GROUP BY role_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code FROM Employees GROUP BY role_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code FROM Employees GROUP BY role_code ORDER BY count(*) 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT role_code FROM Employees GROUP BY role_code ORDER BY count(*) 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T2.role_name , T2.role_description FROM Employees AS T1 JOIN ROLES AS T2 ON T1.role_code = T2.role_code WHERE T1.employee_name = "Ebba" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T2.role_name , T2.role_description FROM Employees AS T1 JOIN ROLES AS T2 ON T1.role_code = T2.role_code WHERE T1.employee_name = "Ebba" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T1.employee_name FROM Employees AS T1 JOIN ROLES AS T2 ON T1.role_code = T2.role_code WHERE T2.role_name = "Editor" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T1.employee_name FROM Employees AS T1 JOIN ROLES AS T2 ON T1.role_code = T2.role_code WHERE T2.role_name = "Editor" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T1.employee_id FROM Employees AS T1 JOIN ROLES AS T2 ON T1.role_code = T2.role_code WHERE T2.role_name = "Human Resource" OR T2.role_name = "Manager" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T1.employee_id FROM Employees AS T1 JOIN ROLES AS T2 ON T1.role_code = T2.role_code WHERE T2.role_name = "Human Resource" OR T2.role_name = "Manager" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT DISTINCT location_code FROM Document_locations |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT DISTINCT location_code FROM Document_locations |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T3.location_name FROM All_documents AS T1 JOIN Document_locations AS T2 ON T1.document_id = T2.document_id JOIN Ref_locations AS T3 ON T2.location_code = T3.location_code WHERE T1.document_name = "Robin CV" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T3.location_name FROM All_documents AS T1 JOIN Document_locations AS T2 ON T1.document_id = T2.document_id JOIN Ref_locations AS T3 ON T2.location_code = T3.location_code WHERE T1.document_name = "Robin CV" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code , date_in_location_from , date_in_locaton_to FROM Document_locations |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code , date_in_location_from , date_in_locaton_to FROM Document_locations |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T1.date_in_location_from , T1.date_in_locaton_to FROM Document_locations AS T1 JOIN All_documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = "Robin CV" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T1.date_in_location_from , T1.date_in_locaton_to FROM Document_locations AS T1 JOIN All_documents AS T2 ON T1.document_id = T2.document_id WHERE T2.document_name = "Robin CV" |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code , count(*) FROM Document_locations GROUP BY location_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code , count(*) FROM Document_locations GROUP BY location_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code FROM Document_locations GROUP BY location_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code FROM Document_locations GROUP BY location_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code FROM Document_locations GROUP BY location_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT location_code FROM Document_locations GROUP BY location_code 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T2.location_name , T1.location_code FROM Document_locations AS T1 JOIN Ref_locations AS T2 ON T1.location_code = T2.location_code GROUP BY T1.location_code ORDER BY count(*) 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T2.location_name , T1.location_code FROM Document_locations AS T1 JOIN Ref_locations AS T2 ON T1.location_code = T2.location_code GROUP BY T1.location_code ORDER BY count(*) 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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T2.employee_name , T3.employee_name FROM Documents_to_be_destroyed AS T1 JOIN Employees AS T2 ON T1.Destruction_Authorised_by_Employee_ID = T2.employee_id JOIN Employees AS T3 ON T1.Destroyed_by_Employee_ID = T3.employee_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT T2.employee_name , T3.employee_name FROM Documents_to_be_destroyed AS T1 JOIN Employees AS T2 ON T1.Destruction_Authorised_by_Employee_ID = T2.employee_id JOIN Employees AS T3 ON T1.Destroyed_by_Employee_ID = T3.employee_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT Destruction_Authorised_by_Employee_ID , count(*) FROM Documents_to_be_destroyed GROUP BY Destruction_Authorised_by_Employee_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT Destruction_Authorised_by_Employee_ID , count(*) FROM Documents_to_be_destroyed GROUP BY Destruction_Authorised_by_Employee_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT Destroyed_by_Employee_ID , count(*) FROM Documents_to_be_destroyed GROUP BY Destroyed_by_Employee_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT Destroyed_by_Employee_ID , count(*) FROM Documents_to_be_destroyed GROUP BY Destroyed_by_Employee_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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_id FROM Employees EXCEPT SELECT Destruction_Authorised_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_id FROM Employees EXCEPT SELECT Destruction_Authorised_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT DISTINCT Destruction_Authorised_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT DISTINCT Destruction_Authorised_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT DISTINCT Destroyed_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT DISTINCT Destroyed_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_id FROM Employees EXCEPT SELECT Destroyed_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT employee_id FROM Employees EXCEPT SELECT Destroyed_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT Destroyed_by_Employee_ID FROM Documents_to_be_destroyed UNION SELECT Destruction_Authorised_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Ref_Document_Types (\nDocument_Type_Code CHAR(15... | You 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 Ref_Document_Types (
Document_Type_Code CHAR(15) NOT NULL,
Document_Type_Name VARCHAR(255) NOT NULL,
Document_Type_Description VARCHAR(255) NOT NULL,
PRIMARY KEY (Document_Type_Code)
)
CREATE TABLE Ref_Calendar (
Calendar_Date DATETIME NOT NULL,
Day_Number INTEGER,
PRIMARY KEY (Calenda... | SELECT Destroyed_by_Employee_ID FROM Documents_to_be_destroyed UNION SELECT Destruction_Authorised_by_Employee_ID FROM Documents_to_be_destroyed |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubname FROM club |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubname FROM club |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM student |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM student |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT DISTINCT fname FROM student |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT DISTINCT fname FROM student |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Tennis Club" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Tennis Club" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Pen and Paper Gaming" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Pen and Paper Gaming" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.fname = "Linda" AND t3.lname = "Smith" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.fname = "Linda" AND t3.lname = "Smith" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.fname = "Tracy" AND t3.lname = "Kim" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.fname = "Tracy" AND t3.lname = "Kim" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" AND t3.sex = "F" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" AND t3.sex = "F" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" AND t3.sex = "M" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" AND t3.sex = "M" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" AND t3.major = "600" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" AND t3.major = "600" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t1.clubname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.major = "600" GROUP BY t1.clubname 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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t1.clubname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.major = "600" GROUP BY t1.clubname 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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t1.clubname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.sex = "F" GROUP BY t1.clubname 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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t1.clubname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t3.sex = "F" GROUP BY t1.clubname 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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubdesc FROM club WHERE clubname = "Tennis Club" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubdesc FROM club WHERE clubname = "Tennis Club" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubdesc FROM club WHERE clubname = "Pen and Paper Gaming" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubdesc FROM club WHERE clubname = "Pen and Paper Gaming" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clublocation FROM club WHERE clubname = "Tennis Club" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clublocation FROM club WHERE clubname = "Tennis Club" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clublocation FROM club WHERE clubname = "Pen and Paper Gaming" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clublocation FROM club WHERE clubname = "Pen and Paper Gaming" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clublocation FROM club WHERE clubname = "Hopkins Student Enterprises" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clublocation FROM club WHERE clubname = "Hopkins Student Enterprises" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubname FROM club WHERE clublocation = "AKW" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT clubname FROM club WHERE clublocation = "AKW" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club WHERE clublocation = "HHH" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(*) FROM club WHERE clublocation = "HHH" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" AND t2.position = "President" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Bootup Baltimore" AND t2.position = "President" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" AND t2.position = "CTO" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT t3.fname , t3.lname FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid JOIN student AS t3 ON t2.stuid = t3.stuid WHERE t1.clubname = "Hopkins Student Enterprises" AND t2.position = "CTO" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(DISTINCT t2.position) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid WHERE t1.clubname = "Bootup Baltimore" |
[
{
"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 Student (\n StuID INTEGER PRIMARY... | You 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 Student (
StuID INTEGER PRIMARY KEY,
LName VARCHAR(12),
Fname VARCHAR(12),
Age INTEGER,
Sex VARCHAR(1),
Major INTEGER,
Advisor INTEGER,
city_code VARCHAR(3)
)
CREATE ... | SELECT count(DISTINCT t2.position) FROM club AS t1 JOIN member_of_club AS t2 ON t1.clubid = t2.clubid WHERE t1.clubname = "Bootup Baltimore" |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.