text
stringlengths 354
1.06k
|
---|
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_78 (place VARCHAR, player VARCHAR)
Question: WHAT IS THE PLACE WITH PLAYER mark o'meara?
[/INST]
Here is the SQLite query to answer to the question: WHAT IS THE PLACE WITH PLAYER mark o'meara?:
```
SELECT place FROM table_name_78 WHERE player = "mark o'meara"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_1342359_5 (candidates VARCHAR, district VARCHAR)
Question: how many candidates with district being california 7
[/INST]
Here is the SQLite query to answer to the question: how many candidates with district being california 7:
```
SELECT COUNT(candidates) FROM table_1342359_5 WHERE district = "California 7"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_92 (genre VARCHAR, release_year_of_first_charted_record VARCHAR, country_of_origin VARCHAR)
Question: Name the genre for release-year of firsst charted less than 1980 and origin of jamaica
[/INST]
Here is the SQLite query to answer to the question: Name the genre for release-year of firsst charted less than 1980 and origin of jamaica:
```
SELECT genre FROM table_name_92 WHERE release_year_of_first_charted_record < 1980 AND country_of_origin = "jamaica"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_249512_2 (a_ VARCHAR, county_ies__ VARCHAR, place_name VARCHAR)
Question: How many counties have a place name of Macedonia?
[/INST]
Here is the SQLite query to answer to the question: How many counties have a place name of Macedonia?:
```
SELECT COUNT(county_ies__)[a_] FROM table_249512_2 WHERE place_name = "Macedonia"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_81 (number_of_contestants VARCHAR, cycle VARCHAR)
Question: What is Number of Contestants, when Cycle is 4?
[/INST]
Here is the SQLite query to answer to the question: What is Number of Contestants, when Cycle is 4?:
```
SELECT number_of_contestants FROM table_name_81 WHERE cycle = 4
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_11944282_1 (allied_unrelated VARCHAR, component VARCHAR)
Question: What is the total amount of allied-unrelated where the component is human capital?
[/INST]
Here is the SQLite query to answer to the question: What is the total amount of allied-unrelated where the component is human capital?:
```
SELECT COUNT(allied_unrelated) FROM table_11944282_1 WHERE component = "Human Capital"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_7 (attendance INTEGER, record VARCHAR)
Question: What is the lowest number of people in attendance when the record was 9–26?
[/INST]
Here is the SQLite query to answer to the question: What is the lowest number of people in attendance when the record was 9–26?:
```
SELECT MIN(attendance) FROM table_name_7 WHERE record = "9–26"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_18 (record VARCHAR, loss VARCHAR)
Question: For the Loss of Plesac (1-5), what is the Record?
[/INST]
Here is the SQLite query to answer to the question: For the Loss of Plesac (1-5), what is the Record?:
```
SELECT record FROM table_name_18 WHERE loss = "plesac (1-5)"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_21 (capital VARCHAR, hangul VARCHAR)
Question: What is the capital of the province with 양주 in Hangul?
[/INST]
Here is the SQLite query to answer to the question: What is the capital of the province with 양주 in Hangul?:
```
SELECT capital FROM table_name_21 WHERE hangul = "양주"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_16 (home VARCHAR, visitor VARCHAR)
Question: What is the home team with the ny rangers as the visitor team?
[/INST]
Here is the SQLite query to answer to the question: What is the home team with the ny rangers as the visitor team?:
```
SELECT home FROM table_name_16 WHERE visitor = "ny rangers"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_8 (type VARCHAR, transfer_window VARCHAR, nat VARCHAR)
Question: What type of transfer window is winter in Ita?
[/INST]
Here is the SQLite query to answer to the question: What type of transfer window is winter in Ita?:
```
SELECT type FROM table_name_8 WHERE transfer_window = "winter" AND nat = "ita"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_1346118_2 (incumbent VARCHAR, candidates VARCHAR)
Question: Who was the incumbent when ran william b. oliver (d) unopposed?
[/INST]
Here is the SQLite query to answer to the question: Who was the incumbent when ran william b. oliver (d) unopposed?:
```
SELECT incumbent FROM table_1346118_2 WHERE candidates = "William B. Oliver (D) Unopposed"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_55 (date VARCHAR, result VARCHAR, battle VARCHAR)
Question: What is the Date of the Bulgarian Victory at the Battle of Arcadiopolis?
[/INST]
Here is the SQLite query to answer to the question: What is the Date of the Bulgarian Victory at the Battle of Arcadiopolis?:
```
SELECT date FROM table_name_55 WHERE result = "bulgarian victory" AND battle = "battle of arcadiopolis"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_40 (country VARCHAR, score INTEGER)
Question: What is the country of the player with a score less than 68?
[/INST]
Here is the SQLite query to answer to the question: What is the country of the player with a score less than 68?:
```
SELECT country FROM table_name_40 WHERE score < 68
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_9 (honorary_professors INTEGER, lecturers VARCHAR, department VARCHAR)
Question: What is the average number of honorary professors in the economics department with 1 lecturer?
[/INST]
Here is the SQLite query to answer to the question: What is the average number of honorary professors in the economics department with 1 lecturer?:
```
SELECT AVG(honorary_professors) FROM table_name_9 WHERE lecturers = 1 AND department = "economics"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_12744399_1 (english_title_translation VARCHAR, japanese_title VARCHAR)
Question: What's the English translation of the Japanese title of the game Ranma ½: Chougi Rambuhen?
[/INST]
Here is the SQLite query to answer to the question: What's the English translation of the Japanese title of the game Ranma ½: Chougi Rambuhen?:
```
SELECT english_title_translation FROM table_12744399_1 WHERE japanese_title = "Ranma ½: Chougi Rambuhen"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_45 (series_ep VARCHAR, netflix VARCHAR)
Question: Which series episode has a netflix figure of s04e21?
[/INST]
Here is the SQLite query to answer to the question: Which series episode has a netflix figure of s04e21?:
```
SELECT series_ep FROM table_name_45 WHERE netflix = "s04e21"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_1342013_37 (incumbent VARCHAR, district VARCHAR)
Question: What is the incumbent for pennsylvania 15
[/INST]
Here is the SQLite query to answer to the question: What is the incumbent for pennsylvania 15:
```
SELECT incumbent FROM table_1342013_37 WHERE district = "Pennsylvania 15"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_63 (game INTEGER, opponent VARCHAR, february VARCHAR)
Question: How many games have the New York Islanders as an opponent before February 7?
[/INST]
Here is the SQLite query to answer to the question: How many games have the New York Islanders as an opponent before February 7?:
```
SELECT SUM(game) FROM table_name_63 WHERE opponent = "new york islanders" AND february < 7
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_66 (round VARCHAR, college VARCHAR, overall VARCHAR)
Question: In what Round with an Overall greater than 306 was the pick from the College of Virginia Tech?
[/INST]
Here is the SQLite query to answer to the question: In what Round with an Overall greater than 306 was the pick from the College of Virginia Tech?:
```
SELECT COUNT(round) FROM table_name_66 WHERE college = "virginia tech" AND overall > 306
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_13196576_2 (team VARCHAR)
Question: What is the total number for 3rd place for ducati xerox?
[/INST]
Here is the SQLite query to answer to the question: What is the total number for 3rd place for ducati xerox?:
```
SELECT COUNT(3 AS rd_pl) FROM table_13196576_2 WHERE team = "Ducati Xerox"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_50 (crowd VARCHAR, venue VARCHAR)
Question: What was the attendance when the VFL played Arden Street Oval?
[/INST]
Here is the SQLite query to answer to the question: What was the attendance when the VFL played Arden Street Oval?:
```
SELECT COUNT(crowd) FROM table_name_50 WHERE venue = "arden street oval"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_70 (year VARCHAR, venue VARCHAR)
Question: In what years did Salina Kosgei compete in Singapore?
[/INST]
Here is the SQLite query to answer to the question: In what years did Salina Kosgei compete in Singapore?:
```
SELECT COUNT(year) FROM table_name_70 WHERE venue = "singapore"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE culture_company (company_name VARCHAR, book_club_id VARCHAR); CREATE TABLE book_club (book_club_id VARCHAR, publisher VARCHAR)
Question: List all company names with a book published by Alyson.
[/INST]
Here is the SQLite query to answer to the question: List all company names with a book published by Alyson.:
```
SELECT T1.company_name FROM culture_company AS T1 JOIN book_club AS T2 ON T1.book_club_id = T2.book_club_id WHERE T2.publisher = 'Alyson'
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_13 (top_division_titles INTEGER, position_in_2012 VARCHAR)
Question: What is the largest number of top division titles with a 2012 position of 10th?
[/INST]
Here is the SQLite query to answer to the question: What is the largest number of top division titles with a 2012 position of 10th?:
```
SELECT MAX(top_division_titles) FROM table_name_13 WHERE position_in_2012 = "10th"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_51 (race_4 VARCHAR, race_1 VARCHAR)
Question: What is Race 4, when Race 1 is 28?
[/INST]
Here is the SQLite query to answer to the question: What is Race 4, when Race 1 is 28?:
```
SELECT race_4 FROM table_name_51 WHERE race_1 = "28"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_65 (expected_end_date VARCHAR, trial_start_date VARCHAR)
Question: What is Expected End Date, when Trial Start Date is Nov 2007?
[/INST]
Here is the SQLite query to answer to the question: What is Expected End Date, when Trial Start Date is Nov 2007?:
```
SELECT expected_end_date FROM table_name_65 WHERE trial_start_date = "nov 2007"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_40 (tournament VARCHAR, surface VARCHAR, date VARCHAR)
Question: Which Tournament has a Surface of hard, and a Date of 24 september 2011?
[/INST]
Here is the SQLite query to answer to the question: Which Tournament has a Surface of hard, and a Date of 24 september 2011?:
```
SELECT tournament FROM table_name_40 WHERE surface = "hard" AND date = "24 september 2011"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_8 (game INTEGER, series VARCHAR)
Question: Which Game has a Series of flyers win 3–0? Question 3
[/INST]
Here is the SQLite query to answer to the question: Which Game has a Series of flyers win 3–0? Question 3:
```
SELECT MAX(game) FROM table_name_8 WHERE series = "flyers win 3–0"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_18047346_5 (tonnes VARCHAR, iata_code VARCHAR)
Question: How many tonnes of cargo did the airport have with the IATA Code IND?
[/INST]
Here is the SQLite query to answer to the question: How many tonnes of cargo did the airport have with the IATA Code IND?:
```
SELECT tonnes FROM table_18047346_5 WHERE iata_code = "IND"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_76 (nanquan VARCHAR, nandao VARCHAR, rank VARCHAR)
Question: Which Nanquan has a Nandao larger than 9.49, and a Rank of 4?
[/INST]
Here is the SQLite query to answer to the question: Which Nanquan has a Nandao larger than 9.49, and a Rank of 4?:
```
SELECT nanquan FROM table_name_76 WHERE nandao > 9.49 AND rank = 4
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_29 (edges INTEGER, dual_archimedean_solid VARCHAR, vertices VARCHAR)
Question: Which Edges have a Dual Archimedean solid of truncated icosidodecahedron, and Vertices larger than 62?
[/INST]
Here is the SQLite query to answer to the question: Which Edges have a Dual Archimedean solid of truncated icosidodecahedron, and Vertices larger than 62?:
```
SELECT MIN(edges) FROM table_name_29 WHERE dual_archimedean_solid = "truncated icosidodecahedron" AND vertices > 62
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_47 (genre VARCHAR, developer_s_ VARCHAR)
Question: Which Genre has a Developer(s) of naughty dog?
[/INST]
Here is the SQLite query to answer to the question: Which Genre has a Developer(s) of naughty dog?:
```
SELECT genre FROM table_name_47 WHERE developer_s_ = "naughty dog"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_28005100_1 (no VARCHAR, lyricist VARCHAR)
Question: Which number was the lyricist ahmed metwally?
[/INST]
Here is the SQLite query to answer to the question: Which number was the lyricist ahmed metwally?:
```
SELECT no FROM table_28005100_1 WHERE lyricist = "Ahmed Metwally"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_2725949_6 (poles VARCHAR, fastest_laps VARCHAR)
Question: Name the number of poles for fastest laps being 6
[/INST]
Here is the SQLite query to answer to the question: Name the number of poles for fastest laps being 6:
```
SELECT COUNT(poles) FROM table_2725949_6 WHERE fastest_laps = 6
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_11734041_11 (player VARCHAR, height_in_ft VARCHAR)
Question: Which player had a height of 6-0?
[/INST]
Here is the SQLite query to answer to the question: Which player had a height of 6-0?:
```
SELECT player FROM table_11734041_11 WHERE height_in_ft = "6-0"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_1341423_13 (district VARCHAR, incumbent VARCHAR)
Question: What district is Henry Hyde in
[/INST]
Here is the SQLite query to answer to the question: What district is Henry Hyde in:
```
SELECT district FROM table_1341423_13 WHERE incumbent = "Henry Hyde"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_99 (result VARCHAR, attendance VARCHAR)
Question: What was the result when the attendance was 25,418?
[/INST]
Here is the SQLite query to answer to the question: What was the result when the attendance was 25,418?:
```
SELECT result FROM table_name_99 WHERE attendance = "25,418"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE Student_Enrolment (semester_name VARCHAR, semester_id VARCHAR); CREATE TABLE Semesters (semester_name VARCHAR, semester_id VARCHAR)
Question: Which semesters do not have any student enrolled? List the semester name.
[/INST]
Here is the SQLite query to answer to the question: Which semesters do not have any student enrolled? List the semester name.:
```
SELECT semester_name FROM Semesters WHERE NOT semester_id IN (SELECT semester_id FROM Student_Enrolment)
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_17058116_7 (high_rebounds VARCHAR, high_points VARCHAR)
Question: Who scored highest rebounds high points is charlie villanueva (32)
[/INST]
Here is the SQLite query to answer to the question: Who scored highest rebounds high points is charlie villanueva (32):
```
SELECT high_rebounds FROM table_17058116_7 WHERE high_points = "Charlie Villanueva (32)"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_42 (COUNT VARCHAR, winner VARCHAR)
Question: How many events did clay win?
[/INST]
Here is the SQLite query to answer to the question: How many events did clay win?:
```
SELECT NOT COUNT AS event FROM table_name_42 WHERE winner = "clay"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_14286908_1 (school VARCHAR, year_of_last_win VARCHAR)
Question: What is the name of the school where the year of last win is 1985-86?
[/INST]
Here is the SQLite query to answer to the question: What is the name of the school where the year of last win is 1985-86?:
```
SELECT school FROM table_14286908_1 WHERE year_of_last_win = "1985-86"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_81 (res VARCHAR, type VARCHAR, opponent VARCHAR)
Question: What was the resolution for KO opposing Cliff Beckett?
[/INST]
Here is the SQLite query to answer to the question: What was the resolution for KO opposing Cliff Beckett?:
```
SELECT res FROM table_name_81 WHERE type = "ko" AND opponent = "cliff beckett"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_41 (byes VARCHAR, losses VARCHAR, wins VARCHAR)
Question: What is the total number of byes that has 13 losses and wins less than 5?
[/INST]
Here is the SQLite query to answer to the question: What is the total number of byes that has 13 losses and wins less than 5?:
```
SELECT COUNT(byes) FROM table_name_41 WHERE losses = 13 AND wins < 5
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_99 (grid INTEGER, laps VARCHAR, constructor VARCHAR, driver VARCHAR)
Question: What is the highest grid value with constructor Mclaren - Mercedes, driver David Coulthard, and has fewer than 66 laps?
[/INST]
Here is the SQLite query to answer to the question: What is the highest grid value with constructor Mclaren - Mercedes, driver David Coulthard, and has fewer than 66 laps?:
```
SELECT MAX(grid) FROM table_name_99 WHERE constructor = "mclaren - mercedes" AND driver = "david coulthard" AND laps < 66
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_7 (pick__number INTEGER, position VARCHAR, overall VARCHAR)
Question: Position of defensive back, and an Overall smaller than 69 is what lowest pick #?
[/INST]
Here is the SQLite query to answer to the question: Position of defensive back, and an Overall smaller than 69 is what lowest pick #?:
```
SELECT MIN(pick__number) FROM table_name_7 WHERE position = "defensive back" AND overall < 69
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_27 (prominence__m_ VARCHAR, elevation__m_ VARCHAR, country VARCHAR, col__m_ VARCHAR)
Question: What is the total prominence number in m of ethiopia, which has a col in m of 1728 and an elevation less than 3,358?
[/INST]
Here is the SQLite query to answer to the question: What is the total prominence number in m of ethiopia, which has a col in m of 1728 and an elevation less than 3,358?:
```
SELECT COUNT(prominence__m_) FROM table_name_27 WHERE country = "ethiopia" AND col__m_ = 1728 AND elevation__m_ < 3 OFFSET 358
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE Customer_Policies (customer_id VARCHAR); CREATE TABLE Customers (customer_details VARCHAR, customer_id VARCHAR); CREATE TABLE Customers (customer_details VARCHAR)
Question: List the details of the customers who do not have any policies.
[/INST]
Here is the SQLite query to answer to the question: List the details of the customers who do not have any policies.:
```
SELECT customer_details FROM Customers EXCEPT SELECT T1.customer_details FROM Customers AS T1 JOIN Customer_Policies AS T2 ON T1.customer_id = T2.customer_id
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_19 (venue VARCHAR, event VARCHAR, competition VARCHAR)
Question: Where was the London Marathon held?
[/INST]
Here is the SQLite query to answer to the question: Where was the London Marathon held?:
```
SELECT venue FROM table_name_19 WHERE event = "marathon" AND competition = "london marathon"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_1566850_9 (centerfold_model VARCHAR)
Question: Who was asked 20 questions in the issue where the centerfold is Marliece Andrada?
[/INST]
Here is the SQLite query to answer to the question: Who was asked 20 questions in the issue where the centerfold is Marliece Andrada?:
```
SELECT 20 AS _questions FROM table_1566850_9 WHERE centerfold_model = "Marliece Andrada"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_88 (against INTEGER, played VARCHAR, drawn VARCHAR, difference VARCHAR)
Question: What is the average Against when the drawn is more than 2 and the Difference of- 17, and a Played smaller than 20?
[/INST]
Here is the SQLite query to answer to the question: What is the average Against when the drawn is more than 2 and the Difference of- 17, and a Played smaller than 20?:
```
SELECT AVG(against) FROM table_name_88 WHERE drawn > 2 AND difference = "- 17" AND played < 20
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_25030512_12 (party VARCHAR, incumbent VARCHAR)
Question: When bill young redistricted from the 10th district is the incumbent what is the party?
[/INST]
Here is the SQLite query to answer to the question: When bill young redistricted from the 10th district is the incumbent what is the party?:
```
SELECT party FROM table_25030512_12 WHERE incumbent = "Bill Young Redistricted from the 10th district"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_23242950_1 (production_code VARCHAR, us_viewers__millions_ VARCHAR)
Question: What's the production code of the episode seen by 7.49 million people in the US?
[/INST]
Here is the SQLite query to answer to the question: What's the production code of the episode seen by 7.49 million people in the US?:
```
SELECT production_code FROM table_23242950_1 WHERE us_viewers__millions_ = "7.49"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE Reservations (Kids VARCHAR, LastName VARCHAR, CheckIn VARCHAR, FirstName VARCHAR)
Question: How many kids stay in the room DAMIEN TRACHSEL checked in on Sep 21, 2010?
[/INST]
Here is the SQLite query to answer to the question: How many kids stay in the room DAMIEN TRACHSEL checked in on Sep 21, 2010?:
```
SELECT Kids FROM Reservations WHERE CheckIn = "2010-09-21" AND FirstName = "DAMIEN" AND LastName = "TRACHSEL"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_87 (date VARCHAR, home_team VARCHAR)
Question: What day is carlton the home side?
[/INST]
Here is the SQLite query to answer to the question: What day is carlton the home side?:
```
SELECT date FROM table_name_87 WHERE home_team = "carlton"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_1926240_1 (max_characters__per_page_row_ INTEGER, bit_rate_ VARCHAR, _mbit_s_ VARCHAR)
Question: What was the max character (per page row) of the encoding with a bit rate of 6.203?
[/INST]
Here is the SQLite query to answer to the question: What was the max character (per page row) of the encoding with a bit rate of 6.203?:
```
SELECT MAX(max_characters__per_page_row_) FROM table_1926240_1 WHERE bit_rate_[_mbit_s_] = "6.203"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_95 (Id VARCHAR)
Question: What is the 2006 total with a 2010 value greater than 417.9?
[/INST]
Here is the SQLite query to answer to the question: What is the 2006 total with a 2010 value greater than 417.9?:
```
SELECT COUNT(2006) FROM table_name_95 WHERE 2010 > 417.9
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_60 (date VARCHAR, opponent_in_the_final VARCHAR)
Question: When did Mathieu play against Flavio Cipolla?
[/INST]
Here is the SQLite query to answer to the question: When did Mathieu play against Flavio Cipolla?:
```
SELECT date FROM table_name_60 WHERE opponent_in_the_final = "flavio cipolla"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_85 (away_team VARCHAR, home_team VARCHAR)
Question: What away team score has carlton home team?
[/INST]
Here is the SQLite query to answer to the question: What away team score has carlton home team?:
```
SELECT away_team AS score FROM table_name_85 WHERE home_team = "carlton"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_63 (rounds VARCHAR, constructor VARCHAR, rider VARCHAR)
Question: What rounds did rider Mika Kallio with a Ducati constructor have?
[/INST]
Here is the SQLite query to answer to the question: What rounds did rider Mika Kallio with a Ducati constructor have?:
```
SELECT rounds FROM table_name_63 WHERE constructor = "ducati" AND rider = "mika kallio"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_14903999_1 (womens_doubles VARCHAR, mixed_doubles VARCHAR)
Question: How many womens doubles had champions the years broddi kristjánsson drífa harðardóttir won mixed doubles
[/INST]
Here is the SQLite query to answer to the question: How many womens doubles had champions the years broddi kristjánsson drífa harðardóttir won mixed doubles:
```
SELECT COUNT(womens_doubles) FROM table_14903999_1 WHERE mixed_doubles = "Broddi Kristjánsson Drífa Harðardóttir"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_10360656_1 (choice VARCHAR, player_name VARCHAR)
Question: What round was Bill Hill drafted?
[/INST]
Here is the SQLite query to answer to the question: What round was Bill Hill drafted?:
```
SELECT choice FROM table_10360656_1 WHERE player_name = "Bill Hill"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_54 (silver VARCHAR, gold VARCHAR, bronze VARCHAR)
Question: How many silver medals were won by the participant(s) that had more than 12 gold medals and 11 bronze medals?
[/INST]
Here is the SQLite query to answer to the question: How many silver medals were won by the participant(s) that had more than 12 gold medals and 11 bronze medals?:
```
SELECT silver FROM table_name_54 WHERE gold > 12 AND bronze = 11
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_93 (wicket VARCHAR, batting_partners VARCHAR, fielding_team VARCHAR)
Question: What was the wicket ranking for the match featuring partners Mohammad Azharuddin and Ajay Jadeja and also a fielding team of Sri Lanka?
[/INST]
Here is the SQLite query to answer to the question: What was the wicket ranking for the match featuring partners Mohammad Azharuddin and Ajay Jadeja and also a fielding team of Sri Lanka?:
```
SELECT wicket FROM table_name_93 WHERE batting_partners = "mohammad azharuddin and ajay jadeja" AND fielding_team = "sri lanka"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_30 (district INTEGER, delegate VARCHAR, took_office VARCHAR)
Question: What is the largest district for delegate Cheryl Glenn, that she had taken after 2006?
[/INST]
Here is the SQLite query to answer to the question: What is the largest district for delegate Cheryl Glenn, that she had taken after 2006?:
```
SELECT MAX(district) FROM table_name_30 WHERE delegate = "cheryl glenn" AND took_office > 2006
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_11318462_5 (open_1st_viii VARCHAR, u15_4th_iv VARCHAR)
Question: what are all the open 1st viii with u15 4th iv being gt
[/INST]
Here is the SQLite query to answer to the question: what are all the open 1st viii with u15 4th iv being gt:
```
SELECT open_1st_viii FROM table_11318462_5 WHERE u15_4th_iv = "GT"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_87 (scores_by_each_individual_judge VARCHAR, date_performed VARCHAR, main_contestant VARCHAR)
Question: Which Scores by each individual judge has a Date performed of august 7, and a Main contestant of karanvir bohra?
[/INST]
Here is the SQLite query to answer to the question: Which Scores by each individual judge has a Date performed of august 7, and a Main contestant of karanvir bohra?:
```
SELECT scores_by_each_individual_judge FROM table_name_87 WHERE date_performed = "august 7" AND main_contestant = "karanvir bohra"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_23 (number INTEGER, player VARCHAR, yards VARCHAR)
Question: What is Larry Centers' average number when there were less than 600 yards?
[/INST]
Here is the SQLite query to answer to the question: What is Larry Centers' average number when there were less than 600 yards?:
```
SELECT AVG(number) FROM table_name_23 WHERE player = "larry centers" AND yards < 600
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_2104176_1 (coast_guard_cross VARCHAR, distinguished_service_cross VARCHAR)
Question: What is the coast guard cross when you recieve the navy distinguished service medal?
[/INST]
Here is the SQLite query to answer to the question: What is the coast guard cross when you recieve the navy distinguished service medal?:
```
SELECT coast_guard_cross FROM table_2104176_1 WHERE distinguished_service_cross = "Navy Distinguished Service Medal"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_42 (wins VARCHAR, byes VARCHAR, losses VARCHAR, against VARCHAR)
Question: What is the total number of Wins, when Losses is less than 10, when Against is less than 1253, and when Byes is less than 0?
[/INST]
Here is the SQLite query to answer to the question: What is the total number of Wins, when Losses is less than 10, when Against is less than 1253, and when Byes is less than 0?:
```
SELECT COUNT(wins) FROM table_name_42 WHERE losses < 10 AND against < 1253 AND byes < 0
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_23 (date_and_time___utc__ VARCHAR, site VARCHAR, rocket VARCHAR, orbit VARCHAR, function VARCHAR)
Question: What date and time has a sub-orbital of orbit, a function of aeronomy research, and a Nike Orion rocket, as well as a Poker Flat site?
[/INST]
Here is the SQLite query to answer to the question: What date and time has a sub-orbital of orbit, a function of aeronomy research, and a Nike Orion rocket, as well as a Poker Flat site?:
```
SELECT date_and_time___utc__ FROM table_name_23 WHERE orbit = "sub-orbital" AND function = "aeronomy research" AND rocket = "nike orion" AND site = "poker flat"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_57 (case_length VARCHAR, base VARCHAR)
Question: Which Case Length has a Base of 14.96 (.589)?
[/INST]
Here is the SQLite query to answer to the question: Which Case Length has a Base of 14.96 (.589)?:
```
SELECT case_length FROM table_name_57 WHERE base = "14.96 (.589)"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_85 (competition VARCHAR, score VARCHAR)
Question: What competition has a Score of 7–0?
[/INST]
Here is the SQLite query to answer to the question: What competition has a Score of 7–0?:
```
SELECT competition FROM table_name_85 WHERE score = "7–0"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_34 (result VARCHAR, category VARCHAR)
Question: What's the result for the category of best actor in a supporting role?
[/INST]
Here is the SQLite query to answer to the question: What's the result for the category of best actor in a supporting role?:
```
SELECT result FROM table_name_34 WHERE category = "best actor in a supporting role"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_85 (losses VARCHAR, team VARCHAR, wins VARCHAR)
Question: How many losses did the team, Sturt, have when they had more than 0 wins?
[/INST]
Here is the SQLite query to answer to the question: How many losses did the team, Sturt, have when they had more than 0 wins?:
```
SELECT COUNT(losses) FROM table_name_85 WHERE team = "sturt" AND wins > 0
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_23224961_2 (season VARCHAR, oberfranken_west VARCHAR)
Question: When sv neuses is the oberfranken west what is the season?
[/INST]
Here is the SQLite query to answer to the question: When sv neuses is the oberfranken west what is the season?:
```
SELECT season FROM table_23224961_2 WHERE oberfranken_west = "SV Neuses"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_56 (shts INTEGER, goalkeeper VARCHAR)
Question: What is the highest SHTS of Kasey Keller
[/INST]
Here is the SQLite query to answer to the question: What is the highest SHTS of Kasey Keller:
```
SELECT MAX(shts) FROM table_name_56 WHERE goalkeeper = "kasey keller"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_54 (record VARCHAR, visitor VARCHAR)
Question: What was the record when the visiting team was Ottawa?
[/INST]
Here is the SQLite query to answer to the question: What was the record when the visiting team was Ottawa?:
```
SELECT record FROM table_name_54 WHERE visitor = "ottawa"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_16 (home_team VARCHAR, away_team VARCHAR)
Question: Who played against the away team hereford united?
[/INST]
Here is the SQLite query to answer to the question: Who played against the away team hereford united?:
```
SELECT home_team FROM table_name_16 WHERE away_team = "hereford united"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_51 (argon VARCHAR, neon VARCHAR)
Question: What argon has a neon of 10.5?
[/INST]
Here is the SQLite query to answer to the question: What argon has a neon of 10.5?:
```
SELECT argon FROM table_name_51 WHERE neon = "10.5"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_27441210_12 (weeks_at__number1 INTEGER, country VARCHAR)
Question: How many weeks was France at #1?
[/INST]
Here is the SQLite query to answer to the question: How many weeks was France at #1?:
```
SELECT MAX(weeks_at__number1) FROM table_27441210_12 WHERE country = "France"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_95 (session VARCHAR, circuit VARCHAR)
Question: What was the session at the circuit of autodrom most?
[/INST]
Here is the SQLite query to answer to the question: What was the session at the circuit of autodrom most?:
```
SELECT session FROM table_name_95 WHERE circuit = "autodrom most"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_14623167_1 (virtual VARCHAR, network VARCHAR)
Question: Name the virtual for Fox
[/INST]
Here is the SQLite query to answer to the question: Name the virtual for Fox:
```
SELECT COUNT(virtual) FROM table_14623167_1 WHERE network = "Fox"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_50 (signed VARCHAR, school VARCHAR)
Question: Was the University of Southern California Signed?
[/INST]
Here is the SQLite query to answer to the question: Was the University of Southern California Signed?:
```
SELECT signed FROM table_name_50 WHERE school = "university of southern california"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_58 (venue VARCHAR, result VARCHAR, opponent VARCHAR)
Question: what is the venue when the result is loss and the opponent is st george-illawarra dragons?
[/INST]
Here is the SQLite query to answer to the question: what is the venue when the result is loss and the opponent is st george-illawarra dragons?:
```
SELECT venue FROM table_name_58 WHERE result = "loss" AND opponent = "st george-illawarra dragons"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_22355_71 (silver INTEGER)
Question: How many silver medalist was won?
[/INST]
Here is the SQLite query to answer to the question: How many silver medalist was won?:
```
SELECT MAX(silver) FROM table_22355_71
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_67 (host_team VARCHAR, final_score VARCHAR)
Question: Who was the host team for the game with the final score of 26-24?
[/INST]
Here is the SQLite query to answer to the question: Who was the host team for the game with the final score of 26-24?:
```
SELECT host_team FROM table_name_67 WHERE final_score = "26-24"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_56 (loss VARCHAR, total_games VARCHAR, draw VARCHAR)
Question: What is the total number of losses for less than 48 games, and less than 7 draws?
[/INST]
Here is the SQLite query to answer to the question: What is the total number of losses for less than 48 games, and less than 7 draws?:
```
SELECT COUNT(loss) FROM table_name_56 WHERE total_games < 48 AND draw < 7
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_36 (grades VARCHAR, enrollment VARCHAR, student_body VARCHAR)
Question: Which Grades has an Enrollment larger htan 443 with a Student body of Co-ed?
[/INST]
Here is the SQLite query to answer to the question: Which Grades has an Enrollment larger htan 443 with a Student body of Co-ed?:
```
SELECT grades FROM table_name_36 WHERE enrollment > 443 AND student_body = "co-ed"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_2454550_1 (most_laps_led VARCHAR, track VARCHAR)
Question: Who had most laps led at Chicagoland speedway?
[/INST]
Here is the SQLite query to answer to the question: Who had most laps led at Chicagoland speedway? :
```
SELECT most_laps_led FROM table_2454550_1 WHERE track = "Chicagoland Speedway"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_142159_1 (name VARCHAR, builder VARCHAR)
Question: What is the name with the builder of Kerr Stuart
[/INST]
Here is the SQLite query to answer to the question: What is the name with the builder of Kerr Stuart:
```
SELECT name FROM table_142159_1 WHERE builder = "Kerr Stuart"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_41 (crowd INTEGER, away_team VARCHAR)
Question: What is the Crowd number for the Away team of Richmond?
[/INST]
Here is the SQLite query to answer to the question: What is the Crowd number for the Away team of Richmond?:
```
SELECT SUM(crowd) FROM table_name_41 WHERE away_team = "richmond"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_14937957_1 (masters VARCHAR, martial_art_style VARCHAR)
Question: How many masters fought using a boxing style?
[/INST]
Here is the SQLite query to answer to the question: How many masters fought using a boxing style?:
```
SELECT COUNT(masters) FROM table_14937957_1 WHERE martial_art_style = "Boxing"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_22 (pick__number INTEGER, overall VARCHAR)
Question: What is the Pick # with an Overall of 19?
[/INST]
Here is the SQLite query to answer to the question: What is the Pick # with an Overall of 19?:
```
SELECT MAX(pick__number) FROM table_name_22 WHERE overall = 19
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_18 (laps VARCHAR, grid VARCHAR, driver VARCHAR)
Question: How many laps did John Love have on a grid less than 11?
[/INST]
Here is the SQLite query to answer to the question: How many laps did John Love have on a grid less than 11?:
```
SELECT laps FROM table_name_18 WHERE grid < 11 AND driver = "john love"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_41 (condition VARCHAR, partial_thromboplastin_time VARCHAR, bleeding_time VARCHAR)
Question: I want the condition that has a partial thromboplastin time of prolonged and unaffected bleeding time
[/INST]
Here is the SQLite query to answer to the question: I want the condition that has a partial thromboplastin time of prolonged and unaffected bleeding time:
```
SELECT condition FROM table_name_41 WHERE partial_thromboplastin_time = "prolonged" AND bleeding_time = "unaffected"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_2 (gold INTEGER, silver VARCHAR, total VARCHAR, rank VARCHAR)
Question: Total larger than 3, and a Rank of 4, and a Silver larger than 0 has what average gold?
[/INST]
Here is the SQLite query to answer to the question: Total larger than 3, and a Rank of 4, and a Silver larger than 0 has what average gold?:
```
SELECT AVG(gold) FROM table_name_2 WHERE total > 3 AND rank = "4" AND silver > 0
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_57 (city VARCHAR, greek_designation VARCHAR, status VARCHAR, us_state_district VARCHAR)
Question: What California city has an active status and a greek designation of established colony?
[/INST]
Here is the SQLite query to answer to the question: What California city has an active status and a greek designation of established colony?:
```
SELECT city FROM table_name_57 WHERE status = "active" AND us_state_district = "california" AND greek_designation = "established colony"
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_54 (semi_final_television_commentator VARCHAR, spokesperson VARCHAR, year_s_ VARCHAR)
Question: What is the semi-final television commentator status in 1962 with an unknown spokesperson?
[/INST]
Here is the SQLite query to answer to the question: What is the semi-final television commentator status in 1962 with an unknown spokesperson?:
```
SELECT semi_final_television_commentator FROM table_name_54 WHERE spokesperson = "unknown" AND year_s_ = 1962
``` |
[INST] Write SQLite query to answer the following question given the database schema. Please wrap your code answer using ```:
Schema: CREATE TABLE table_name_36 (tie_no VARCHAR, home_team VARCHAR)
Question: What is the tie no of the game where exeter city was the home team?
[/INST]
Here is the SQLite query to answer to the question: What is the tie no of the game where exeter city was the home team?:
```
SELECT tie_no FROM table_name_36 WHERE home_team = "exeter city"
``` |