Question: Which year has the most customer orders?

SELECT strftime('%Y', order_date) FROM cust_order GROUP BY strftime('%Y', order_date) ORDER BY COUNT(strftime('%Y', order_date)) DESC LIMIT 1

Which year has the most customer orders ?


Question: What is the last name of the contact individual from the Labour party organization who was contacted most recently?

SELECT t3.individual_last_name FROM organizations AS t1 JOIN organization_contact_individuals AS t2 ON t1.organization_id  =  t2.organization_id JOIN individuals AS t3 ON t2.individual_id  =  t3.individual_id WHERE t1.organization_name  =  "Labour Party" ORDER BY t2.date_contact_to DESC LIMIT 1

What is the last name of the contact individual from the Labour party organization who was contacted most recently ?

O O O B-COLUMN I-COLUMN O O B-COLUMN B-TABLE O O B-COLUMN I-COLUMN B-TABLE O O B-TABLE O O O


Question: Retrieve all the last names of authors in alphabetical order.

SELECT lname FROM authors ORDER BY lname

Retrieve all the last names of authors in alphabetical order .


Question: What percentage of players have Legbreak skill?

SELECT CAST(SUM(CASE WHEN T2.Bowling_skill = ' Legbreak' THEN 1 ELSE 0 END) AS REAL) * 100 / TOTAL(T1.Player_Id) FROM Player AS T1 INNER JOIN Bowling_Style AS T2 ON T1.Bowling_skill = T2.Bowling_Id

What percentage of players have Legbreak skill ?


Question: What is the short name of the football team Queens Park Rangers?

SELECT team_short_name FROM Team WHERE team_long_name = 'Queens Park Rangers'

What is the short name of the football team Queens Park Rangers ?

O O O B-COLUMN I-COLUMN O O O B-TABLE B-VALUE I-VALUE I-VALUE O


Question: Which weather station does store no.20 belong to?

SELECT station_nbr FROM relation WHERE store_nbr = 20

Which weather station does store no.20 belong to ?


Question: Among the players who were born in July and August, how many of them got in the Hall of Fame?

SELECT COUNT(T1.playerID) FROM Master AS T1 INNER JOIN HOF AS T2 ON T1.hofID = T2.hofID WHERE T1.birthMon IN (7, 8)

Among the players who were born in July and August , how many of them got in the Hall of Fame ?

O O B-COLUMN O O B-COLUMN O B-VALUE O B-VALUE O O O O O O O O O O O O


Question: What is the number of the year round school in Los Angeles?

SELECT COUNT(school_year_round) FROM projects WHERE school_city = 'Los Angeles' AND school_year_round = 't'

What is the number of the year round school in Los Angeles ?

O O O O O O B-COLUMN I-COLUMN I-COLUMN O B-VALUE I-VALUE O


Question: Which Minnesota North Stars' goalkeeper had the most Goal Againsts in his play time?

SELECT playerID FROM Goalies AS T1 INNER JOIN Teams AS T2 ON T1.tmID = T2.tmID AND T1.year = T2.year WHERE T2.name = 'Minnesota North Stars' GROUP BY T1.playerID ORDER BY SUM(T1.GA) DESC LIMIT 1

Which Minnesota North Stars ' goalkeeper had the most Goal Againsts in his play time ?

O B-VALUE I-VALUE I-VALUE O O O O O B-TABLE O O O B-COLUMN O O


Question: How much is the salary of the first ever employee that was hired?

SELECT salary FROM employee ORDER BY hiredate ASC LIMIT 1

How much is the salary of the first ever employee that was hired ?

O O O O B-COLUMN O O O O B-TABLE O O B-COLUMN O


Question: In the "https://github.com/wallerdev/htmlsharp.git", give all the linearized sequenced of API calls.

SELECT T3.ApiCalls FROM Repo AS T1 INNER JOIN Solution AS T2 ON T1.Id = T2.RepoId INNER JOIN Method AS T3 ON T2.Id = T3.SolutionId WHERE T1.Url = 'https://github.com/wallerdev/htmlsharp.git'

O O O B-VALUE O O O O O O O O B-COLUMN I-COLUMN O


Question: What are the average height and weight across males (sex is M)?

SELECT avg(height) ,  avg(weight) FROM people WHERE sex  =  'M'

What are the average height and weight across males ( sex is M ) ?

O O O O B-COLUMN O B-COLUMN O O O B-COLUMN O B-VALUE O O


Question: Which ranking system is criteria "Total Shanghai" in?

SELECT T1.system_name FROM ranking_system AS T1 INNER JOIN ranking_criteria AS T2 ON T1.id = T2.ranking_system_id WHERE T2.criteria_name = 'Total Shanghai'

Which ranking system is criteria " Total Shanghai " in ?


Question: Find pilots who own plane Piper Cub but not B-52 Bomber.

SELECT pilot_name FROM pilotskills WHERE plane_name  =  'Piper Cub' EXCEPT SELECT pilot_name FROM pilotskills WHERE plane_name  =  'B-52 Bomber'

Find pilots who own plane Piper Cub but not B-52 Bomber .

O B-COLUMN O O B-COLUMN B-VALUE I-VALUE O O B-VALUE I-VALUE O


Question: Find the first names of all instructors who have taught some course and the course description.

SELECT T2.emp_fname ,  T3.crs_description FROM CLASS AS T1 JOIN employee AS T2 ON T1.prof_num  =  T2.emp_num JOIN course AS T3 ON T1.crs_code  =  T3.crs_code

Find the first names of all instructors who have taught some course and the course description .

O O B-COLUMN I-COLUMN O O O O O O O B-COLUMN O O B-TABLE B-COLUMN O


Question: List the affiliations shared by more than three city channels.

SELECT Affiliation FROM city_channel GROUP BY Affiliation HAVING COUNT(*)  >  3

List the affiliations shared by more than three city channels .

O O B-COLUMN O O O O B-VALUE B-TABLE I-TABLE O


Question: Show the average price of hotels for each star rating code.

SELECT star_rating_code ,  avg(price_range) FROM HOTELS GROUP BY star_rating_code

Show the average price of hotels for each star rating code .

O O O B-COLUMN O B-TABLE O O B-COLUMN I-COLUMN I-COLUMN O


Question: How many members attended the "Women's Soccer" event?

SELECT COUNT(T2.link_to_member) FROM event AS T1 INNER JOIN attendance AS T2 ON T1.event_id = T2.link_to_event WHERE T1.event_name = 'Women''s Soccer'

How many members attended the " Women 's Soccer " event ?

O O B-COLUMN B-TABLE O O B-VALUE I-VALUE I-VALUE O B-TABLE O


Question: Please give the ids of the oldest films that got the most ratings.

SELECT DISTINCT T1.movieid FROM u2base AS T1 INNER JOIN movies AS T2 ON T1.movieid = T2.movieid WHERE T1.rating = 5 AND T2.year = 1

Please give the ids of the oldest films that got the most ratings .

O O O B-COLUMN O O O O O O O O B-COLUMN O


Question: How many allergies does Mrs. Saundra Monahan have?

SELECT COUNT(DISTINCT T2.code) FROM patients AS T1 INNER JOIN allergies AS T2 ON T1.patient = T2.PATIENT WHERE T1.prefix = 'Mrs.' AND T1.first = 'Saundra' AND T1.last = 'Monahan'

How many allergies does Mrs. Saundra Monahan have ?

O O B-TABLE O B-VALUE B-VALUE B-VALUE O O


Question: What percentage of no comment reviews are from "Teen" content rating apps?

SELECT CAST(COUNT(CASE WHEN T1.`Content Rating` = 'Teen' THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T1.App) FROM playstore AS T1 INNER JOIN user_reviews AS T2 ON T1.App = T2.App WHERE T2.Translated_Review = 'nan'

What percentage of no comment reviews are from " Teen " content rating apps ?

O O B-TABLE O O O B-COLUMN O O B-TABLE O O B-VALUE I-VALUE O


Question: List the names of members in ascending order of age.

SELECT Name FROM member ORDER BY Age ASC

List the names of members in ascending order of age .

O O B-COLUMN O B-TABLE O O O O B-COLUMN O


Question: What are the coordinates of the school where project 'Look, Look, We Need a Nook!' Was donated to and what resource type is it?

SELECT T2.school_latitude, T2.school_longitude, T2.resource_type FROM essays AS T1 INNER JOIN projects AS T2 ON T1.projectid = T2.projectid WHERE T1.title LIKE 'Look, Look, We Need a Nook!'

What are the coordinates of the school where project ' Look , Look , We Need a Nook ! ' Was donated to and what resource type is it ?

O O O O O O B-COLUMN O B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O O O O O B-COLUMN I-COLUMN O O O


Question: For all list titles with at least 200 movies in the list, what is their average number of followers?

SELECT AVG(list_followers) FROM lists WHERE list_movie_number > 200

For all list titles with at least 200 movies in the list , what is their average number of followers ?

O O O B-COLUMN I-COLUMN O B-VALUE I-VALUE O O B-TABLE O B-COLUMN I-COLUMN I-COLUMN O O O O O O


Question: How many percent of countries in North America use English?

SELECT CAST(SUM(IIF(T2.Language = 'English', 1, 0)) AS REAL) * 100 / COUNT(T1.Code) FROM Country AS T1 INNER JOIN CountryLanguage AS T2 ON T1.Code = T2.CountryCode

How many percent of countries in North America use English ?


Question: Who are the customers that had more than 1 policy? List the customer details and id.

SELECT T1.customer_details ,  T1.customer_id FROM Customers AS T1 JOIN Customer_Policies AS T2 ON T1.Customer_id  =  T2.Customer_id GROUP BY T1.customer_id HAVING count(*)  >  1

Who are the customers that had more than 1 policy ? List the customer details and i d.

O O B-COLUMN O O O B-VALUE O B-TABLE O O O O O O O O O


Question: What is the official language of China?

SELECT T2.Language FROM Country AS T1 INNER JOIN CountryLanguage AS T2 ON T1.Code = T2.CountryCode WHERE T1.Name = 'China' AND T2.IsOfficial = 'T'

What is the official language of China ?


Question: What are the distinct wineries which produce wines costing between 50 and 100?

SELECT DISTINCT Winery FROM WINE WHERE Price BETWEEN 50 AND 100

What are the distinct wineries which produce wines costing between 50 and 100 ?

O O O O B-COLUMN O O B-TABLE O O B-VALUE O B-VALUE O


Question: Which year was the goalie who had the most postseaon shots Against in 2008 born?

SELECT T1.birthYear FROM Master AS T1 INNER JOIN Goalies AS T2 ON T1.playerID = T2.playerID WHERE T2.year = 2008 ORDER BY T2.PostSA DESC LIMIT 1

Which year was the goalie who had the most postseaon shots Against in 2008 born ?

O B-COLUMN O O B-TABLE O O O O B-COLUMN O O O B-VALUE O O


Question: What's the royalty for the bestseller book?

SELECT royalty FROM titles ORDER BY ytd_sales DESC LIMIT 1

What 's the royalty for the bestseller book ?


Question: Who is the largest donor by amount? Give the donation id and the total amount of the donation.

SELECT donationid, donation_total FROM donations ORDER BY donation_total DESC LIMIT 1

Who is the largest donor by amount ? Give the donation i d and the total amount of the donation .

O O O O O O O O O O B-TABLE B-COLUMN I-COLUMN O O O O O O B-COLUMN O


Question: List the names of perpetrators in descending order of the year.

SELECT T1.Name FROM people AS T1 JOIN perpetrator AS T2 ON T1.People_ID  =  T2.People_ID ORDER BY T2.Year DESC

List the names of perpetrators in descending order of the year .

O O B-COLUMN O B-TABLE O O O O O B-COLUMN O


Question: Find the name of the source user with the highest average trust score.

SELECT T1.name FROM useracct AS T1 JOIN trust AS T2 ON T1.u_id  =  T2.source_u_id GROUP BY T2.source_u_id ORDER BY avg(trust) DESC LIMIT 1

Find the name of the source user with the highest average trust score .

O O B-COLUMN O O B-COLUMN B-TABLE O O O O B-COLUMN O O


Question: For each station, return its longitude and the average duration of trips that started from the station.

SELECT T1.name ,  T1.long ,  avg(T2.duration) FROM station AS T1 JOIN trip AS T2 ON T1.id  =  T2.start_station_id GROUP BY T2.start_station_id

For each station , return its longitude and the average duration of trips that started from the station .

O O O O O O B-COLUMN O O O B-TABLE O O B-TABLE I-TABLE O O O O


Question: Which procedures and medications were received by the patient with the third-degree burn?

SELECT DISTINCT T1.DESCRIPTION, T3.DESCRIPTION FROM procedures AS T1 INNER JOIN conditions AS T2 ON T1.patient = T2.PATIENT INNER JOIN medications AS T3 ON T2.patient = T3.PATIENT WHERE T2.DESCRIPTION = 'Third degree burn'

Which procedures and medications were received by the patient with the third - degree burn ?

O B-TABLE O B-TABLE O O O O B-COLUMN O O B-VALUE I-VALUE I-VALUE I-VALUE O


Question: How many Belgian men have competed in an Olympic Games?

SELECT COUNT(T2.person_id) FROM noc_region AS T1 INNER JOIN person_region AS T2 ON T1.id = T2.region_id INNER JOIN person AS T3 ON T2.person_id = T3.id WHERE T1.region_name = 'Belgium' AND T3.gender = 'M'

How many Belgian men have competed in an Olympic Games ?

O O B-COLUMN O O B-TABLE O O O B-TABLE I-TABLE


Question: Return the average transaction amount, as well as the total amount of all transactions.

SELECT avg(transaction_amount) ,  sum(transaction_amount) FROM Financial_transactions

Return the average transaction amount , as well as the total amount of all transactions .

O O O B-COLUMN I-COLUMN O O O O O O O O O B-TABLE O


Question: Find the student ID and login name of the student with the most course enrollments

SELECT T1.student_id ,  T2.login_name FROM Student_Course_Enrolment AS T1 JOIN Students AS T2 ON T1.student_id  =  T2.student_id GROUP BY T1.student_id ORDER BY COUNT(*) DESC LIMIT 1

O O B-COLUMN I-COLUMN O B-COLUMN I-COLUMN O O B-TABLE O O B-TABLE I-TABLE I-TABLE


Question: Find the ids of the problems that are reported by the staff whose last name is Bosco.

SELECT T1.problem_id FROM problems AS T1 JOIN staff AS T2 ON T1.reported_by_staff_id = T2.staff_id WHERE T2.staff_last_name = "Bosco"

Find the ids of the problems that are reported by the staff whose last name is Bosco .

O O B-COLUMN O O B-TABLE O O B-COLUMN I-COLUMN O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN O


Question: Find the customer with the highest membership level and return his or her card credit.

SELECT Card_Credit FROM customer ORDER BY Level_of_Membership DESC LIMIT 1

Find the customer with the highest membership level and return his or her card credit .

O O B-COLUMN O O O O O B-COLUMN O O O O O O O


Question: Tell the hometown county for "Adela O'Gallagher".

SELECT T2.county FROM member AS T1 INNER JOIN zip_code AS T2 ON T1.zip = T2.zip_code WHERE T1.first_name = 'Adela' AND T1.last_name = 'O''Gallagher'

Tell the hometown county for " Adela O'Gallagher " .


Question: Which kind of policy type was chosen by the most customers?

SELECT Policy_Type_Code FROM Customer_Policies GROUP BY Policy_Type_Code ORDER BY count(*) DESC LIMIT 1

Which kind of policy type was chosen by the most customers ?

O O O B-COLUMN I-COLUMN O O O O O B-TABLE O


Question: How many eastbound trains have rectangular-shaped head cars?

SELECT COUNT(T.train_id) FROM (SELECT T1.train_id FROM cars AS T1 INNER JOIN trains AS T2 ON T1.train_id = T2.id WHERE T1.position = 1 AND T2.direction = 'east' AND T1.shape = 'rectangle' GROUP BY T1.train_id)as T

How many eastbound trains have rectangular - shaped head cars ?

O O B-VALUE B-TABLE O B-VALUE O B-COLUMN O B-TABLE O


Question: Calculate the percentage of households in residential areas of countries over 10000.

SELECT CAST(COUNT(CASE WHEN T2.households > 10000 THEN T1.zip_code ELSE NULL END) AS REAL) * 100 / COUNT(T1.zip_code) FROM country AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code

Calculate the percentage of households in residential areas of countries over 10000 .

O O O O B-COLUMN O O O O B-TABLE O B-VALUE O


Question: Show the title of games that are played by both players from college "Oklahoma" and players from college "Auburn".

SELECT T1.Title FROM game AS T1 JOIN game_player AS T2 ON T1.Game_ID  =  T2.Game_ID JOIN player AS T3 ON T2.Player_ID  =  T3.Player_ID WHERE T3.College  =  "Oklahoma" INTERSECT SELECT T1.Title FROM game AS T1 JOIN game_player AS T2 ON T1.Game_ID  =  T2.Game_ID JOIN player AS T3 ON T2.Player_ID  =  T3.Player_ID WHERE T3.College  =  "Auburn"

Show the title of games that are played by both players from college " Oklahoma " and players from college " Auburn " .

O B-COLUMN O O O O O O O O O O O O O O O O O O O O O O


Question: What is the full address of the restaurant named "Sanuki Restaurant"?

SELECT T2.city, T1.street_num, T1.street_name FROM location AS T1 INNER JOIN generalinfo AS T2 ON T1.id_restaurant = T2.id_restaurant WHERE T2.label = 'sanuki restaurant'

What is the full address of the restaurant named " Sanuki Restaurant " ?

O O O O O O O B-COLUMN B-COLUMN O B-VALUE I-VALUE O O


Question: Please list the assumed name of all the facilities inspected by Joshua Rosa.

SELECT DISTINCT T3.dba_name FROM employee AS T1 INNER JOIN inspection AS T2 ON T1.employee_id = T2.employee_id INNER JOIN establishment AS T3 ON T2.license_no = T3.license_no WHERE T1.first_name = 'Joshua' AND T1.last_name = 'Rosa'

Please list the assumed name of all the facilities inspected by Joshua Rosa .

O O O O B-COLUMN O O O O B-TABLE O B-VALUE B-VALUE O


Question: Among the users who received high compliments from other users, which users joined Yelp earliest?

SELECT T2.user_id FROM Users AS T1 INNER JOIN Users_Compliments AS T2 ON T1.user_id = T2.user_id WHERE T2.number_of_compliments = 'High' AND T1.user_yelping_since_year = ( SELECT MIN(user_yelping_since_year) FROM Users )

Among the users who received high compliments from other users , which users joined Yelp earliest ?

O O O O O B-VALUE B-TABLE O O B-TABLE O O B-COLUMN O B-COLUMN O O


Question: How many postal points with unique post office types are there in Ohio?

SELECT COUNT(T2.zip_code) FROM state AS T1 INNER JOIN zip_data AS T2 ON T1.abbreviation = T2.state WHERE T1.name = 'Ohio' AND T2.type = 'Unique Post Office'

How many postal points with unique post office types are there in Ohio ?

O O O O O B-VALUE I-VALUE I-VALUE B-COLUMN O B-COLUMN I-COLUMN B-VALUE O


Question: Identify all the restaurants in Marin County by their id.

SELECT T1.id_restaurant FROM generalinfo AS T1 INNER JOIN geographic AS T2 ON T1.city = T2.city WHERE T2.county = 'marin county'

Identify all the restaurants in Marin County by their i d.

O O O B-COLUMN O B-VALUE B-COLUMN O O B-COLUMN I-COLUMN


Question: What are the details of all organizations that are described as Sponsors and sort the results in ascending order?

SELECT organisation_details FROM Organisations AS T1 JOIN organisation_Types AS T2 ON T1.organisation_type  =  T2.organisation_type WHERE T2.organisation_type_description  =  'Sponsor' ORDER BY organisation_details

What are the details of all organizations that are described as Sponsors and sort the results in ascending order ?

O O B-COLUMN O O O B-TABLE I-TABLE O O O O O B-TABLE I-TABLE O O O O O


Question: What are the distinct hometowns of gymnasts with total points more than 57.5?

SELECT DISTINCT T2.Hometown FROM gymnast AS T1 JOIN people AS T2 ON T1.Gymnast_ID  =  T2.People_ID WHERE T1.Total_Points  >  57.5

What are the distinct hometowns of gymnasts with total points more than 57.5 ?

O O O O B-COLUMN O B-TABLE O B-COLUMN I-COLUMN O O B-VALUE O


Question: Which country has the least organization membership?

SELECT country FROM organization WHERE country IN ( SELECT Code FROM country ) GROUP BY country ORDER BY COUNT(NAME) LIMIT 1

Which country has the least organization membership ?


Question: Write down the call id of clients whose first name start with alphabet "B".

SELECT T2.call_id FROM client AS T1 INNER JOIN callcenterlogs AS T2 ON T1.client_id = T2.`rand client` WHERE T1.first LIKE 'B%'

Write down the call i d of clients whose first name start with alphabet " B " .

O O O B-COLUMN I-COLUMN I-COLUMN O B-TABLE O B-COLUMN O O O O O B-VALUE O O


Question: What is the distance between Boston and Newark?

SELECT distance FROM Direct_distance AS T1 JOIN City AS T2 ON T1.city1_code  =  T2.city_code JOIN City AS T3 ON T1.city2_code  =  T3.city_code WHERE T2.city_name  =  "Boston" AND T3.city_name  =  "Newark"

What is the distance between Boston and Newark ?


Question: Among the movies, what percentage are horror?

SELECT CAST(SUM(IIF(T2.name = 'horror', 1, 0)) AS REAL) * 100 / COUNT(T2.category_id) FROM film_category AS T1 INNER JOIN category AS T2 ON T1.category_id = T2.category_id

Among the movies , what percentage are horror ?


Question: What is the difference in population between the two nations where the tallest peak is located?

SELECT * FROM mountain AS T1 INNER JOIN geo_mountain AS T2 ON T1.Name = T2.Mountain INNER JOIN province AS T3 ON T3.Country = T2.Country INNER JOIN country AS T4 ON T4.Code = T3.Country WHERE T1.Name = ( SELECT Name FROM mountain ORDER BY Height DESC LIMIT 1 )

What is the difference in population between the two nations where the tallest peak is located ?


Question: Give the order status code that is most frequent across customer orders.

SELECT order_status_code FROM Customer_orders GROUP BY order_status_code ORDER BY count(*) DESC LIMIT 1

Give the order status code that is most frequent across customer orders .

O O B-COLUMN I-COLUMN I-COLUMN O O O O O B-TABLE I-TABLE O


Question: What is the total number of airlines?


Question: List all the keywords with "christmas" in them.

SELECT keyword_name FROM keyword WHERE keyword_name LIKE '%christmas%'

List all the keywords with " christmas " in them .


Question: Find the state and country of all cities with post code starting with 4.

SELECT state_province_county ,  country FROM addresses WHERE zip_postcode LIKE "4%"

Find the state and country of all cities with post code starting with 4 .

O O B-COLUMN O B-COLUMN O O O O B-COLUMN I-COLUMN O O B-COLUMN O


Question: Provide the category name of the Chef Anton's Gumbo Mix product that New Orleans Cajun Delights company has.

SELECT T3.CategoryName FROM Suppliers AS T1 INNER JOIN Products AS T2 ON T1.SupplierID = T2.SupplierID INNER JOIN Categories AS T3 ON T2.CategoryID = T3.CategoryID WHERE T1.CompanyName = 'New Orleans Cajun Delights' AND T2.ProductName LIKE 'Chef Anton%s Gumbo Mix'

Provide the category name of the Chef Anton 's Gumbo Mix product that New Orleans Cajun Delights company has .

O O B-COLUMN B-COLUMN O O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE B-COLUMN O O


Question: What is the average overall rating of the players born before the year 1986?

SELECT SUM(t2.overall_rating) / COUNT(t1.id) FROM Player AS t1 INNER JOIN Player_Attributes AS t2 ON t1.player_api_id = t2.player_api_id WHERE SUBSTR(t1.birthday, 1, 4) < '1986'

What is the average overall rating of the players born before the year 1986 ?

O O O O B-COLUMN I-COLUMN O O B-TABLE O O O O B-VALUE O


Question: Count the number of distinct channel owners.

SELECT count(DISTINCT OWNER) FROM channel

Count the number of distinct channel owners .


Question: How many persons participated in the Sapporo Olympics?

SELECT COUNT(T1.person_id) FROM games_competitor AS T1 INNER JOIN games_city AS T2 ON T1.games_id = T2.games_id INNER JOIN city AS T3 ON T2.city_id = T3.id WHERE T3.city_name = 'Sapporo'

How many persons participated in the Sapporo Olympics ?


Question: Count the number of accounts.


Question: Find the details of all the markets that are accessible by walk or bus.

SELECT T1.Market_Details FROM Street_Markets AS T1 JOIN TOURIST_ATTRACTIONS AS T2 ON T1.Market_ID  =  T2.Tourist_Attraction_ID WHERE T2.How_to_Get_There  =  "walk" OR  T2.How_to_Get_There  =  "bus"

Find the details of all the markets that are accessible by walk or bus .

O O B-COLUMN O O O B-TABLE O O O O B-COLUMN O B-COLUMN O


Question: List the grape, winery and year of the wines whose price is bigger than 100 ordered by year.

SELECT Grape ,  Winery ,  YEAR FROM WINE WHERE Price  >   100 ORDER BY YEAR

List the grape , winery and year of the wines whose price is bigger than 100 ordered by year .

O O B-COLUMN O B-COLUMN O B-COLUMN O O B-TABLE O B-COLUMN O O O B-VALUE O O O O


Question: The oldest SJS patient's medical laboratory work was completed on what date, and what age was the patient when they initially arrived at the hospital?

SELECT T1.Date, STRFTIME('%Y', T2.`First Date`) - STRFTIME('%Y', T2.Birthday),T2.Birthday FROM Laboratory AS T1 INNER JOIN Patient AS T2 ON T1.ID = T2.ID WHERE T2.Diagnosis = 'SJS' AND T2.Birthday IS NOT NULL ORDER BY T2.Birthday ASC LIMIT 1

The oldest SJS patient 's medical laboratory work was completed on what date , and what age was the patient when they initially arrived at the hospital ?

O O O O O O B-TABLE O O B-COLUMN O O B-TABLE B-COLUMN O O O O O O O O O O O O O O


Question: Which player from Wake Forest college did the most offensive rebounds than defensive rebounds in the all-star? Please mention the full name of the player including the middle name if have any.

SELECT T1.firstName, T1.middleName, T1.lastName FROM players AS T1 INNER JOIN player_allstar AS T2 ON T1.playerID = T2.playerID WHERE T1.college = 'Wake Forest' AND T2.o_rebounds > T2.d_rebounds

Which player from Wake Forest college did the most offensive rebounds than defensive rebounds in the all - star ? Please mention the full name of the player including the middle name if have any .

O O O B-VALUE I-VALUE B-COLUMN O O O B-COLUMN I-COLUMN O B-COLUMN I-COLUMN O O B-TABLE I-TABLE I-TABLE O O O O O B-COLUMN O O B-TABLE O O B-COLUMN B-COLUMN O O O O


Question: List at least 5 active business ID that are good for groups and dancing.

SELECT T2.business_id FROM Attributes AS T1 INNER JOIN Business_Attributes AS T2 ON T1.attribute_id = T2.attribute_id INNER JOIN Business AS T3 ON T2.business_id = T3.business_id WHERE T2.attribute_value LIKE 'TRUE' AND T1.attribute_name LIKE 'Good for Dancing' AND T1.attribute_name LIKE 'Good for Groups' LIMIT 5

List at least 5 active business ID that are good for groups and dancing .

O O O O O B-TABLE B-COLUMN O O B-VALUE I-VALUE I-VALUE O B-VALUE O


Question: How many customers who live in California that are retailers?

SELECT COUNT(*) FROM customer WHERE cust_type = 'retailer' AND state = 'CA'

How many customers who live in California that are retailers ?


Question: How many draw games happened on 2018/8/7 for National League?

SELECT COUNT(T1.FTR) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'National League' AND T1.Date = '2018-08-07' AND T1.FTR = 'D'

How many draw games happened on 2018/8/7 for National League ?


Question: List all conference name, year, and location.

SELECT conference_name ,  YEAR ,  LOCATION FROM conference

List all conference name , year , and location .

O O B-TABLE B-COLUMN O B-COLUMN O O B-COLUMN O


Question: Please list any five cities that have an unidentified county and region.

SELECT city FROM geographic WHERE county = 'unknown' AND region = 'unknown' LIMIT 5

Please list any five cities that have an unidentified county and region .

O O O O B-COLUMN O O O O B-COLUMN O B-COLUMN O


Question: Find the faculty rank that has the least members.

SELECT rank FROM Faculty GROUP BY rank ORDER BY count(*) ASC LIMIT 1

Find the faculty rank that has the least members .


Question: What are the teams with the most technicians?

SELECT Team FROM technician GROUP BY Team ORDER BY COUNT(*) DESC LIMIT 1

What are the teams with the most technicians ?


Question: How many object samples in image no.908 are in the class of tip?

SELECT SUM(CASE WHEN T2.OBJ_CLASS = 'tip' THEN 1 ELSE 0 END) FROM IMG_OBJ AS T1 INNER JOIN OBJ_CLASSES AS T2 ON T1.OBJ_CLASS_ID = T2.OBJ_CLASS_ID WHERE T1.IMG_ID = 908

How many object samples in image no.908 are in the class of tip ?

O O B-TABLE O O B-COLUMN B-VALUE O O O B-COLUMN O B-VALUE O


Question: What is the name of the customer who has the most policies listed?

SELECT t1.customer_name FROM customers AS t1 JOIN customers_policies AS t2 ON t1.customer_id  =  t2.customer_id GROUP BY t1.customer_name ORDER BY count(*) DESC LIMIT 1

What is the name of the customer who has the most policies listed ?

O O O B-COLUMN O O B-TABLE O O O O B-TABLE O O


Question: What are the names of all songs that have a lower rating than some song of blues genre?

SELECT song_name FROM song WHERE rating  <  (SELECT max(rating) FROM song WHERE genre_is  =  "blues")

What are the names of all songs that have a lower rating than some song of blues genre ?

O O O O O O O O O O O B-COLUMN O B-COLUMN B-TABLE O B-COLUMN B-COLUMN O


Question: Who is the customer with an order shipped on March 5, 2013, in the eastern region?

SELECT DISTINCT T2.`Customer Name` FROM east_superstore AS T1 INNER JOIN people AS T2 ON T1.`Customer ID` = T2.`Customer ID` WHERE T1.`Ship Date` = '2013-03-05'

Who is the customer with an order shipped on March 5 , 2013 , in the eastern region ?

O O O B-COLUMN O O O B-COLUMN O O O O B-VALUE O O O B-TABLE I-TABLE O


Question: Find the average age of all students living in the each city.

SELECT avg(age) ,  city_code FROM student GROUP BY city_code

Find the average age of all students living in the each city .

O O O B-COLUMN O O B-TABLE O O O O B-COLUMN O


Question: Find the name and city of the airport which is the source for the most number of flight routes.

SELECT T1.name ,  T1.city ,  T2.src_apid FROM airports AS T1 JOIN routes AS T2 ON T1.apid  =  T2.src_apid GROUP BY T2.src_apid ORDER BY count(*) DESC LIMIT 1

Find the name and city of the airport which is the source for the most number of flight routes .

O O B-COLUMN O B-COLUMN O O B-TABLE O O O B-COLUMN O O O O O O B-TABLE O


Question: Is donor “22cbc920c9b5fa08dfb331422f5926b5” a teacher?

SELECT DISTINCT is_teacher_acct FROM donations WHERE donor_acctid = '22cbc920c9b5fa08dfb331422f5926b5'

Is donor “ 22cbc920c9b5fa08dfb331422f5926b5 ” a teacher ?


Question: How many people with the name Alex are single and occupying organization level of 1?

SELECT COUNT(T1.BusinessEntityID) FROM Employee AS T1 INNER JOIN Person AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID WHERE T2.FirstName = 'Alex' AND T1.MaritalStatus = 'S' AND T1.OrganizationLevel = 1

How many people with the name Alex are single and occupying organization level of 1 ?

O B-TABLE O O O B-COLUMN I-COLUMN O O O O O O O O O


Question: Among the tags with tag ID below 15, how many of them have 20 count of posts and below?

SELECT COUNT(id) FROM tags WHERE Count <= 20 AND Id < 15

Among the tags with tag ID below 15 , how many of them have 20 count of posts and below ?

O O B-TABLE O O B-COLUMN O B-VALUE O O O O O O B-VALUE B-COLUMN O O O O O


Question: How many films did actor Daryl Wahlberg appear in?

SELECT COUNT(T1.film_id) FROM film_actor AS T1 INNER JOIN actor AS T2 ON T1.actor_id = T2.actor_id WHERE T2.first_name = 'DARYL' AND T2.last_name = 'WAHLBERG'

How many films did actor Daryl Wahlberg appear in ?

O O B-COLUMN I-COLUMN B-TABLE B-VALUE B-VALUE O O O


Question: What campuses opened before 1800?

SELECT campus FROM campuses WHERE YEAR  <  1800


Question: What is allergy type of a cat allergy?

SELECT allergytype FROM Allergy_type WHERE allergy  =  "Cat"

O O B-TABLE B-COLUMN O O B-COLUMN B-COLUMN O


Question: Which element is the least numerous in non-carcinogenic molecules?

SELECT T.element FROM (SELECT T1.element, COUNT(DISTINCT T1.molecule_id) FROM atom AS T1 INNER JOIN molecule AS T2 ON T1.molecule_id = T2.molecule_id WHERE T2.label = '-' GROUP BY T1.element ORDER BY COUNT(DISTINCT T1.molecule_id) ASC LIMIT 1) t

Which element is the least numerous in non - carcinogenic molecules ?

O B-COLUMN O O O O O O B-VALUE O B-TABLE O


Question: For the students with an intelligence of 5, list the full name and courses taken by them who have less than a 3 GPA.

SELECT T1.f_name, T1.l_name, T3.name FROM student AS T1 INNER JOIN registration AS T2 ON T1.student_id = T2.student_id INNER JOIN course AS T3 ON T2.course_id = T3.course_id WHERE T1.intelligence = 5 AND T1.gpa < 3

For the students with an intelligence of 5 , list the full name and courses taken by them who have less than a 3 GPA .

O O B-TABLE O O B-COLUMN O B-VALUE O O O O B-COLUMN O B-TABLE O O O O O O O O B-VALUE B-COLUMN O


Question: Among the male customers with an level of education of 4 and below, list their income K.

SELECT INCOME_K FROM Demog WHERE GEOID IN ( SELECT GEOID FROM Customers WHERE EDUCATIONNUM < 4 AND SEX = 'Male' )

Among the male customers with an level of education of 4 and below , list their income K.

O O O B-COLUMN I-COLUMN O O O B-TABLE O O O O O O O O O


Question: Name the product that was registered in the sales order 'SO - 0005951'.

SELECT T FROM ( SELECT DISTINCT CASE  WHEN T2.OrderNumber = 'SO - 0005951' THEN T1.`Product Name` ELSE NULL END AS T FROM Products T1 INNER JOIN `Sales Orders` T2 ON T2._ProductID = T1.ProductID ) WHERE T IS NOT NULL

Name the product that was registered in the sales order ' SO - 0005951 ' .

O O O B-TABLE I-TABLE O O O O O O O O O O O


Question: Show the location name for document "Robin CV".

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"

Show the location name for document " Robin CV " .

O O B-COLUMN I-COLUMN O B-COLUMN O B-COLUMN I-COLUMN O O


Question: What is the average top speed of vehicles?

What is the average top speed of vehicles ?


Question: Among all the claims, which claims have a claimed amount larger than the average? List the date the claim was made and the date it was settled.

SELECT Date_Claim_Made ,  Date_Claim_Settled FROM Claims WHERE Amount_Claimed  >  ( SELECT avg(Amount_Claimed) FROM Claims )

Among all the claims , which claims have a claimed amount larger than the average ? List the date the claim was made and the date it was settled .

O O O O O O B-TABLE O O B-COLUMN I-COLUMN O O O O O O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN I-COLUMN O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN O


Question: What is the average number of cities of markets with low film market estimate bigger than 10000?

SELECT avg(T2.Number_cities) FROM film_market_estimation AS T1 JOIN market AS T2 ON T1.Market_ID  =  T2.Market_ID WHERE T1.Low_Estimate  >  10000

What is the average number of cities of markets with low film market estimate bigger than 10000 ?

O O O O B-COLUMN I-COLUMN I-COLUMN O O O O B-TABLE B-TABLE B-COLUMN O O B-VALUE O


Question: How many male legislators are Roman Catholic?

SELECT COUNT(*) FROM current WHERE religion_bio = 'Roman Catholic' AND gender_bio = 'M'

How many male legislators are Roman Catholic ?


Question: Count the total quantity for sales from id 1 to 10.

SELECT SUM(Quantity) FROM Sales WHERE SalesID BETWEEN 1 AND 10

Count the total quantity for sales from i d 1 to 10 .

O O O B-COLUMN O B-TABLE O B-COLUMN I-COLUMN B-VALUE O B-VALUE O


Question: Calculate the difference between Emil Blonsky's weight and Charles Chandler's weight.

SELECT ( SELECT weight_kg FROM superhero WHERE full_name LIKE 'Emil Blonsky' ) - ( SELECT weight_kg FROM superhero WHERE full_name LIKE 'Charles Chandler' ) AS CALCULATE

Calculate the difference between Emil Blonsky 's weight and Charles Chandler 's weight .

O O O O B-VALUE I-VALUE O O O B-VALUE I-VALUE O B-COLUMN O


Question: Give the YouTube ID of the channel 'RepWassermanSchultz.'

SELECT youtube_id FROM `social-media` WHERE youtube = 'RepWassermanSchultz'

Give the YouTube ID of the channel ' RepWassermanSchultz . '

O O B-COLUMN B-COLUMN O O O O B-VALUE O O


Question: List the full name of the customer who purchased the most quantity of products.

SELECT T1.FirstName, T1.LastName FROM Customers AS T1 INNER JOIN Sales AS T2 ON T1.CustomerID = T2.CustomerID ORDER BY T2.Quantity DESC LIMIT 1

List the full name of the customer who purchased the most quantity of products .

O O O O O O O B-COLUMN I-COLUMN O O O O O O


Question: What is the average amount of items ordered in each order?

SELECT avg(order_quantity) FROM order_items

What is the average amount of items ordered in each order ?

O O O O O O B-TABLE I-TABLE O O B-COLUMN O


Question: How many distinct transaction types are used in the transactions?

SELECT COUNT(DISTINCT transaction_type_code) FROM TRANSACTIONS

How many distinct transaction types are used in the transactions ?

O O O B-COLUMN I-COLUMN O O O O B-TABLE O


Question: For movie titled 'Welcome to the Dollhouse', how many percentage of the ratings were rated with highest score.

SELECT CAST(SUM(CASE WHEN T2.rating_score = 5 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM movies AS T1 INNER JOIN ratings AS T2 ON T1.movie_id = T2.movie_id WHERE T1.movie_title = 'Welcome to the Dollhouse'

For movie titled ' Welcome to the Dollhouse ' , how many percentage of the ratings were rated with highest score .

O B-TABLE B-COLUMN O B-VALUE I-VALUE I-VALUE I-VALUE O O O O O O O B-TABLE O O O O B-COLUMN O


Question: Did legendsID "P194502" personally attend his Hall of Fame dedication?

SELECT IIF(T1.note = 'posthumous', 'YES', 'NO') FROM AwardsMisc AS T1 RIGHT JOIN Master AS T2 ON T1.ID = T2.playerID WHERE T2.legendsID = 'P194502'

Did legendsID " P194502 " personally attend his Hall of Fame dedication ?

B-COLUMN B-COLUMN O B-VALUE O B-VALUE B-TABLE O O O O O O


Question: How many furniture components are there in total?

SELECT sum(num_of_component) FROM furniture

How many furniture components are there in total ?


Question: What is the minimum shipping charge for "OVERSEAS - DELUXE"?

SELECT ShipBase FROM ShipMethod WHERE Name = 'OVERSEAS - DELUXE'

What is the minimum shipping charge for " OVERSEAS - DELUXE " ?

O O O O B-COLUMN O O O B-VALUE I-VALUE I-VALUE O O


Question: List the names of teams that do not have any drivers.

SELECT Team FROM team WHERE Team_ID NOT IN (SELECT Team_ID FROM team_driver)

List the names of teams that do not have any drivers .

O O O O B-TABLE B-COLUMN O O O B-TABLE B-COLUMN O


Question: What are the names of the managers for gas stations that are operated by the ExxonMobil company?

SELECT T3.manager_name FROM station_company AS T1 JOIN company AS T2 ON T1.company_id  =  T2.company_id JOIN gas_station AS T3 ON T1.station_id  =  T3.station_id WHERE T2.company  =  'ExxonMobil'

What are the names of the managers for gas stations that are operated by the ExxonMobil company ?

O O O B-COLUMN O O B-COLUMN O B-TABLE B-COLUMN O O O O O B-VALUE B-TABLE O


Question: Find the ward office's address and phone number of the ward where the most crimes without arrest occurred.

SELECT T2.ward_office_address, T2.ward_office_phone FROM Crime AS T1 INNER JOIN Ward AS T2 ON T2.ward_no = T1.ward_no WHERE T1.arrest = 'FALSE' GROUP BY T2.ward_office_address, T2.ward_office_phone ORDER BY COUNT(T1.arrest) DESC LIMIT 1

Find the ward office 's address and phone number of the ward where the most crimes without arrest occurred .

O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN O B-COLUMN O O O O O O O B-TABLE O B-COLUMN O O


Question: What is the episode rating with the most award won?

SELECT T1.rating FROM Episode AS T1 INNER JOIN Award AS T2 ON T1.episode_id = T2.episode_id WHERE T2.result = 'Winner' GROUP BY T1.episode_id ORDER BY COUNT(T2.award_id) DESC LIMIT 1

What is the episode rating with the most award won ?

O O O B-COLUMN O B-COLUMN B-COLUMN O O O O


Question: List the name of artists who have released albums and mixtape from 1980 to 1985 in "dance" genre.

SELECT COUNT(T1.artist) FROM torrents AS T1 INNER JOIN tags AS T2 ON T1.id = T2.id WHERE T2.tag = 'dance' AND T1.groupYear BETWEEN 1980 AND 1985 AND T1.releaseType LIKE 'album' OR T1.releaseType LIKE 'mixtape'

List the name of artists who have released albums and mixtape from 1980 to 1985 in " dance " genre .

O O B-COLUMN O B-TABLE O O B-TABLE O B-COLUMN I-COLUMN O O O O O O O O O O


Question: List the title of the earliest published Japanese book.

SELECT T1.title FROM book AS T1 INNER JOIN book_language AS T2 ON T1.language_id = T2.language_id WHERE T2.language_name = 'Japanese' ORDER BY T1.publication_date ASC LIMIT 1

List the title of the earliest published Japanese book .

O O B-COLUMN O O O B-COLUMN B-VALUE B-TABLE O


Question: List top 10 employee work longest in the company. List employee's first and last name.

SELECT first_name , last_name FROM employees ORDER BY hire_date ASC LIMIT 10;

List top 10 employee work longest in the company . List employee 's first and last name .

O O B-COLUMN O O O O B-COLUMN O O O O O B-COLUMN O O O O


Question: List out all end stations for a bicycle that were making a trip starting from 2nd at South Park station? Only retain the unique value.

SELECT DISTINCT end_station_name FROM trip WHERE start_station_name = '2nd at South Park'

List out all end stations for a bicycle that were making a trip starting from 2nd at South Park station ? Only retain the unique value .

O O O B-COLUMN I-COLUMN O O O O O O O B-TABLE O O B-VALUE I-VALUE I-VALUE I-VALUE B-COLUMN O O O O O O O


Question: What are the different card type codes?

SELECT DISTINCT card_type_code FROM Customers_Cards

What are the different card type codes ?


Question: What is the highest acc percent score in the competition?

SELECT acc_percent FROM basketball_match ORDER BY acc_percent DESC LIMIT 1

What is the highest acc percent score in the competition ?


Question: What model year of truck delivered the ship ID 1233?

SELECT T1.model_year FROM truck AS T1 INNER JOIN shipment AS T2 ON T1.truck_id = T2.truck_id WHERE T2.ship_id = '1233'

What model year of truck delivered the ship ID 1233 ?

O B-COLUMN I-COLUMN O B-TABLE O O B-COLUMN I-COLUMN B-VALUE O


Question: Among the films that the customer RUTH MARTINEZ has rented, what is the title of the one with the highest replacement cost?

SELECT T4.title FROM customer AS T1 INNER JOIN rental AS T2 ON T1.customer_id = T2.customer_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film AS T4 ON T3.film_id = T4.film_id WHERE T1.first_name = 'RUTH' AND T1.last_name = 'MARTINEZ' ORDER BY T4.replacement_cost DESC LIMIT 1

Among the films that the customer RUTH MARTINEZ has rented , what is the title of the one with the highest replacement cost ?

O O B-TABLE O O B-TABLE B-VALUE B-VALUE O B-TABLE O O O O B-COLUMN O O O O O O B-COLUMN I-COLUMN O


Question: What are the ids of courses without prerequisites?

SELECT course_id FROM course EXCEPT SELECT course_id FROM prereq

What are the ids of courses without prerequisites ?


Question: Calculate the percentage of congress representatives from the Democrat party. Among them, how many postal points are in the Hawaii state?

SELECT CAST(SUM(CASE WHEN T1.party = 'Democrat' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*), SUM(CASE WHEN T1.state = 'Hawaii' THEN 1 ELSE 0 END) FROM congress AS T1 INNER JOIN zip_congress AS T2 ON T1.cognress_rep_id = T2.district

Calculate the percentage of congress representatives from the Democrat party . Among them , how many postal points are in the Hawaii state ?

O O O O O O O O B-TABLE O B-COLUMN O O O O B-VALUE O O O O O B-COLUMN O O


Question: Give the ids of cookes that are cheaper than any croissant.

SELECT id FROM goods WHERE food  =  "Cookie" AND price  <  (SELECT min(price) FROM goods WHERE food  =  'Croissant')

Give the ids of cookes that are cheaper than any croissant .

O O B-COLUMN O B-COLUMN O O O O O B-VALUE O


Question: What is the total number of customers across banks?

What is the total number of customers across banks ?


Question: Please list the releases that have been downloaded for more than 20000 times.

SELECT groupName FROM torrents WHERE totalSnatched > 20000

Please list the releases that have been downloaded for more than 20000 times .


Question: If Jose Rodriguez tried his best, how many percentage can his salary raise without changing his position?

SELECT 100 * (CAST(REPLACE(SUBSTR(T2.maxsalary, 4), ',', '') AS REAL) - CAST(REPLACE(SUBSTR(T1.salary, 4), ',', '') AS REAL)) / CAST(REPLACE(SUBSTR(T1.salary, 4), ',', '') AS REAL) AS per FROM employee AS T1  INNER JOIN position AS T2  ON T1.positionID = T2.positionID WHERE T1.firstname = 'Jose' AND T1.lastname = 'Rodriguez'

If Jose Rodriguez tried his best , how many percentage can his salary raise without changing his position ?

O B-VALUE B-VALUE O O O O O O O O O B-COLUMN O O O O B-TABLE O


Question: Show the ids for all the faculty members who have at least 2 students.

SELECT T1.FacID FROM Faculty AS T1 JOIN Student AS T2 ON T1.FacID  =  T2.advisor GROUP BY T1.FacID HAVING count(*)  >=  2

Show the ids for all the faculty members who have at least 2 students .

O O B-COLUMN O O O B-TABLE O O O O O B-VALUE B-TABLE O


Question: How many products are out of stock?

SELECT COUNT(ProductID) FROM ProductVendor WHERE OnOrderQty = 0


Question: How many districts did John Conyers, Jr. serve in total?

SELECT COUNT(T3.district) FROM ( SELECT T2.district FROM current AS T1 INNER JOIN `current-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T1.official_full_name = 'John Conyers, Jr.' GROUP BY T2.district ) T3

How many districts did John Conyers , Jr. serve in total ?

O O B-COLUMN O B-VALUE I-VALUE I-VALUE I-VALUE O O O O


Question: How many diffrent dorm amenities are there?

How many diffrent dorm amenities are there ?


Question: List the days in 2013 when rain and fog occurred together and find the id of bikes borrowed on these days.

SELECT T2.date, T1.bike_id FROM trip AS T1 INNER JOIN weather AS T2 ON T2.zip_code = T1.zip_code WHERE SUBSTR(CAST(T2.date AS TEXT), -4) = '2013' AND T2.events = 'Fog-Rain'

List the days in 2013 when rain and fog occurred together and find the i d of bikes borrowed on these days .

O O O O B-VALUE O O O B-VALUE O O O O O B-COLUMN I-COLUMN O B-COLUMN O O O O O


Question: How many customers who are in Norway and have credit line under 220000?

SELECT COUNT(creditLimit) FROM customers WHERE creditLimit < 220000 AND country = 'Norway'

How many customers who are in Norway and have credit line under 220000 ?

O O B-TABLE O O O B-VALUE O O B-COLUMN O O B-VALUE O


Question: Please list the names of all the suppliers for parts under Brand#55.

SELECT T3.s_name FROM part AS T1 INNER JOIN partsupp AS T2 ON T1.p_partkey = T2.ps_partkey INNER JOIN supplier AS T3 ON T2.ps_suppkey = T3.s_suppkey WHERE T1.p_brand = 'Brand#55'

Please list the names of all the suppliers for parts under Brand#55 .

O O O B-COLUMN O O O B-TABLE O B-TABLE O B-VALUE O


Question: List the names of the browser that are compatible with both 'CACHEbox' and 'Fasterfox'.

SELECT T3.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id JOIN browser AS T3 ON T2.browser_id  =  T3.id WHERE T1.name  =  'CACHEbox' INTERSECT SELECT T3.name FROM web_client_accelerator AS T1 JOIN accelerator_compatible_browser AS T2 ON T2.accelerator_id  =  T1.id JOIN browser AS T3 ON T2.browser_id  =  T3.id WHERE T1.name  =  'Fasterfox'

List the names of the browser that are compatible with both ' CACHEbox ' and ' Fasterfox ' .

O O B-COLUMN O O B-TABLE O O B-TABLE O O O B-VALUE O O O B-VALUE O O


Question: Provide the age of the tallest competitor.

SELECT T2.age FROM person AS T1 INNER JOIN games_competitor AS T2 ON T1.id = T2.person_id ORDER BY T1.height DESC LIMIT 1

Provide the age of the tallest competitor .


Question: Return the name of the discount that corresponds to the most rental history records.

SELECT T2.name FROM renting_history AS T1 JOIN discount AS T2 ON T1.discount_id  =  T2.id GROUP BY T2.id ORDER BY count(*) DESC LIMIT 1

Return the name of the discount that corresponds to the most rental history records .

O O B-COLUMN O O B-TABLE O O O O O B-TABLE I-TABLE O O


Question: How many male students (sex is 'M') are allergic to any type of food?

SELECT count(*) FROM Student WHERE sex  =  "M" AND StuID IN (SELECT StuID FROM Has_allergy AS T1 JOIN Allergy_Type AS T2 ON T1.Allergy  =  T2.Allergy WHERE T2.allergytype  =  "food")

How many male students ( sex is ' M ' ) are allergic to any type of food ?

O O O B-TABLE O B-COLUMN O O B-COLUMN O O O B-COLUMN O O B-COLUMN O B-COLUMN O


Question: What is the average discount for the parts made by Manufacturer#5?

SELECT AVG(T3.l_discount) FROM part AS T1 INNER JOIN partsupp AS T2 ON T1.p_partkey = T2.ps_partkey INNER JOIN lineitem AS T3 ON T2.ps_suppkey = T3.l_suppkey WHERE T1.p_mfgr = 'Manufacturer#5'

What is the average discount for the parts made by Manufacturer#5 ?

O O O O B-COLUMN O O B-TABLE O O B-VALUE O


Question: List all the crimes of the narcotic type that exist.

SELECT secondary_description FROM IUCR WHERE primary_description = 'NARCOTICS' GROUP BY secondary_description

List all the crimes of the narcotic type that exist .


Question: Find the number of tied games (the value of "ties" is '1') in 1885 postseason.

SELECT count(*) FROM postseason WHERE YEAR  =  1885 AND ties  =  1;

Find the number of tied games ( the value of " ties " is ' 1 ' ) in 1885 postseason .

O O O O O O O O O O O B-COLUMN O O O B-VALUE O O O B-VALUE B-TABLE O


Question: How many vendors are having their products ordered with an average delivery time of 25 days?

SELECT COUNT(DISTINCT BusinessEntityID) FROM ProductVendor WHERE AverageLeadTime = 25

How many vendors are having their products ordered with an average delivery time of 25 days ?

O O O O O O B-TABLE O O O B-COLUMN O O O B-VALUE O O


Question: What are the full names of the countries in South Asia that belongs to the low income group?

SELECT LongName FROM Country WHERE IncomeGroup = 'Low income' AND Region = 'South Asia'

What are the full names of the countries in South Asia that belongs to the low income group ?

O O O O O O O B-TABLE O B-VALUE I-VALUE O O O O B-VALUE I-VALUE B-COLUMN O


Question: What is the stocked quantity of products manufactured from location ID 40?

SELECT COUNT(*) FROM WorkOrderRouting AS T1 INNER JOIN BillOfMaterials AS T2 ON T1.LocationID = T2.ProductAssemblyID INNER JOIN WorkOrder AS T3 ON T3.WorkOrderID = T1.WorkOrderID WHERE T1.LocationID = 40

What is the stocked quantity of products manufactured from location ID 40 ?

O O O O O O B-COLUMN O O B-COLUMN I-COLUMN B-VALUE O


Question: What are the names of institutions, ordered by the years in which they were founded?

SELECT Name FROM institution ORDER BY Founded ASC

What are the names of institutions , ordered by the years in which they were founded ?

O O O B-COLUMN O B-TABLE O O O O O O O O O B-COLUMN O


Question: List all staff in the Shipping and Receiving department who are hired in 2009.

SELECT T1.FirstName, T1.LastName FROM Person AS T1 INNER JOIN Employee AS T2 ON T1.BusinessEntityID = T2.BusinessEntityID INNER JOIN EmployeeDepartmentHistory AS T3 ON T2.BusinessEntityID = T3.BusinessEntityID INNER JOIN Department AS T4 ON T3.DepartmentID = T4.DepartmentID WHERE STRFTIME('%Y', T2.HireDate) = '2009' AND T4.Name = 'Shipping and Receiving'

List all staff in the Shipping and Receiving department who are hired in 2009 .

O O O O O B-VALUE I-VALUE I-VALUE B-TABLE O O B-COLUMN O B-VALUE O


Question: What are the ids and names of the companies that operated more than one flight?

SELECT T1.id ,  T1.name FROM operate_company AS T1 JOIN flight AS t2 ON T1.id  =  T2.company_id GROUP BY T1.id HAVING count(*)  >  1

What are the ids and names of the companies that operated more than one flight ?

O O O B-COLUMN O B-COLUMN O O B-COLUMN O B-TABLE O O B-VALUE B-TABLE O


Question: Which brand is most common among people in their twenties?

SELECT T.phone_brand FROM ( SELECT T2.phone_brand, COUNT(T2.phone_brand) AS num FROM gender_age AS T1 INNER JOIN phone_brand_device_model2 AS T2 ON T1.device_id = T2.device_id WHERE T1.age BETWEEN 20 AND 30 GROUP BY T2.phone_brand ) AS T ORDER BY T.num DESC LIMIT 1

Which brand is most common among people in their twenties ?


Question: For all patients who are older than 55 years old, what is the percentage of female who has abnormal prothrombin time (PT)?

SELECT CAST(SUM(CASE WHEN T2.PT >= 14 AND T1.SEX = 'F' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE STRFTIME('%Y', CURRENT_TIMESTAMP) - STRFTIME('%Y', T1.Birthday) > 55

For all patients who are older than 55 years old , what is the percentage of female who has abnormal prothrombin time ( PT ) ?

O O B-TABLE O O O O B-VALUE B-VALUE O O O O O O O B-VALUE O O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN I-COLUMN O


Question: How many distinct cities does the employees live in?

SELECT COUNT(DISTINCT city) FROM EMPLOYEE

How many distinct cities does the employees live in ?


Question: Mention the language of Untouchables Sunrise film and calculate its rental cost per day.

SELECT T2.name, T1.replacement_cost / T1.rental_duration AS cost FROM film AS T1 INNER JOIN language AS T2 ON T1.language_id = T2.language_id WHERE T1.title = 'UNTOUCHABLES SUNRISE'

Mention the language of Untouchables Sunrise film and calculate its rental cost per day .

O O B-TABLE O B-VALUE I-VALUE B-TABLE O O O B-COLUMN B-COLUMN O O O


Question: Which resource type is commonly bought by the Los Angeles Unified School District?

SELECT T1.project_resource_type FROM resources AS T1 INNER JOIN projects AS T2 ON T1.projectid = T2.projectid WHERE T2.school_district = 'Los Angeles Unif Sch Dist' GROUP BY T2.school_district ORDER BY COUNT(T1.project_resource_type) DESC LIMIT 1

Which resource type is commonly bought by the Los Angeles Unified School District ?

O B-COLUMN I-COLUMN O O O O O B-VALUE I-VALUE I-VALUE B-COLUMN I-COLUMN O


Question: What is the id and flavor of the cheapest cookie?

SELECT id ,  flavor FROM goods WHERE food  =  "Cookie" ORDER BY price LIMIT 1

What is the i d and flavor of the cheapest cookie ?

O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN O O O B-COLUMN O


Question: For the patients with the normal glutamic pylvic transaminase level, how many of them are male?

SELECT COUNT(T1.ID) FROM Patient AS T1 INNER JOIN Laboratory AS T2 ON T1.ID = T2.ID WHERE T2.GOT < 60 AND T1.SEX = 'M'

For the patients with the normal glutamic pylvic transaminase level , how many of them are male ?

O O O B-TABLE I-TABLE I-TABLE I-TABLE O O B-COLUMN O O O O O O O O


Question: What are the course codes for every class that the student with the last name Smithson took?

SELECT T1.crs_code FROM CLASS AS T1 JOIN enroll AS T2 ON T1.class_code  =  T2.class_code JOIN student AS T3 ON T3.stu_num  =  T2.stu_num WHERE T3.stu_lname  =  'Smithson'

What are the course codes for every class that the student with the last name Smithson took ?

O O O B-COLUMN I-COLUMN O O B-TABLE O O B-TABLE O O B-COLUMN I-COLUMN B-VALUE O O


Question: What is the date of birth of every customer whose status code is 'Good Customer'?

SELECT date_of_birth FROM Customers WHERE customer_status_code  =  'Good Customer'

What is the date of birth of every customer whose status code is ' Good Customer ' ?

O O O B-COLUMN I-COLUMN I-COLUMN O O B-COLUMN O B-COLUMN I-COLUMN O O B-VALUE B-TABLE O O


Question: Give the number of planes that took off from Los Angeles International airport on 2018/8/27.

SELECT SUM(CASE WHEN T2.FL_DATE = '2018/8/27' THEN 1 ELSE 0 END) AS count FROM Airports AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.ORIGIN WHERE T1.Description = 'Los Angeles, CA: Los Angeles International'

Give the number of planes that took off from Los Angeles International airport on 2018/8/27 .

O O B-TABLE O O O B-COLUMN B-VALUE O B-VALUE O O O O O O


Question: How many bookings does each booking status have? List the booking status code and the number of corresponding bookings.

SELECT 	booking_status_code ,  COUNT(*) FROM Apartment_Bookings GROUP BY booking_status_code

How many bookings does each booking status have ? List the booking status code and the number of corresponding bookings .

O O O O B-TABLE O O O O B-COLUMN O O O O O O O O O O O


Question: What is the last name of the student who got a grade A in the class with code 10018.

SELECT T1.stu_lname FROM student AS T1 JOIN enroll AS T2 ON T1.stu_num  =  T2.stu_num WHERE T2.enroll_grade  =  'A' AND T2.class_code  =  10018

What is the last name of the student who got a grade A in the class with code 10018 .

O O O B-COLUMN I-COLUMN O O B-TABLE O O O B-COLUMN B-VALUE O O B-COLUMN O B-COLUMN B-VALUE O


Question: What percentage more for the "Women's Clothing" Yelp businesses to "Men's Clothing"?

SELECT CAST(SUM(CASE WHEN T2.category_name LIKE 'Women''s Clothing' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.business_id) - CAST(SUM(CASE WHEN T2.category_name LIKE 'Men''s Clothing' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.business_id) AS "more percentage" FROM Business_Categories AS T1 INNER JOIN Categories AS T2 ON T1.category_id = T2.category_id

What percentage more for the " Women 's Clothing " Yelp businesses to " Men 's Clothing " ?

O O O O O O B-VALUE I-VALUE I-VALUE O O B-COLUMN O O B-VALUE I-VALUE I-VALUE O O


Question: How many students enlisted in the navy?

SELECT COUNT(name) FROM enlist WHERE organ = 'navy'

How many students enlisted in the navy ?


Question: Give the product's name brought by Aaron Alexander.

SELECT DISTINCT T1.Name FROM Products AS T1 INNER JOIN Sales AS T2 ON T1.ProductID = T2.ProductID INNER JOIN Customers AS T3 ON T2.CustomerID = T3.CustomerID WHERE T3.FirstName = 'Aaron' AND T3.LastName = 'Alexander'

Give the product 's name brought by Aaron Alexander .

O O B-TABLE O B-COLUMN O O B-VALUE B-VALUE O


Question: Find the id of the courses that do not have any prerequisite?

SELECT course_id FROM course EXCEPT SELECT course_id FROM prereq

Find the i d of the courses that do not have any prerequisite ?

O O B-COLUMN I-COLUMN O O B-TABLE O O O O O B-TABLE O


Question: What is the product type with least number of products?

SELECT product_type_code FROM Products GROUP BY product_type_code ORDER BY count(*) ASC LIMIT 1

What is the product type with least number of products ?

O O O B-COLUMN I-COLUMN O O O O B-TABLE O


Question: Give the state that has the most students.

SELECT T1.state FROM City AS T1 JOIN Student AS T2 ON T1.city_code  =  T2.city_code GROUP BY T1.state ORDER BY count(*) DESC LIMIT 1

Give the state that has the most students .


Question: Which high income group countries are from Asia?

SELECT CountryCode, Region FROM Country WHERE (IncomeGroup = 'High income: OECD' OR IncomeGroup = 'High income: nonOECD') AND Region LIKE '%Asia%'

Which high income group countries are from Asia ?

O B-VALUE B-COLUMN I-COLUMN B-TABLE O O B-VALUE O


Question: For each race name, What is the maximum fastest lap speed for races after 2004 ordered by year?

SELECT max(T2.fastestlapspeed) ,  T1.name ,  T1.year FROM races AS T1 JOIN results AS T2 ON T1.raceid = T2.raceid WHERE T1.year > 2014 GROUP BY T1.name ORDER BY T1.year

For each race name , What is the maximum fastest lap speed for races after 2004 ordered by year ?

O O B-COLUMN B-COLUMN O O O O O B-COLUMN I-COLUMN I-COLUMN O B-TABLE O B-VALUE O O B-COLUMN O


Question: What is the id and name of the enzyme that can interact with the most medicines as an activator?

SELECT T1.id ,  T1.name FROM enzyme AS T1 JOIN medicine_enzyme_interaction AS T2 ON T1.id  =  T2.enzyme_id WHERE T2.interaction_type  =  'activitor' GROUP BY T1.id ORDER BY count(*) DESC LIMIT 1

What is the i d and name of the enzyme that can interact with the most medicines as an activator ?

O O O B-COLUMN I-COLUMN O B-COLUMN O O B-TABLE O O B-COLUMN O O O B-TABLE O O B-VALUE O


Question: What are the names of the employees who authorised the destruction and the employees who destroyed the corresponding documents?

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;

What are the names of the employees who authorised the destruction and the employees who destroyed the corresponding documents ?

O O O B-COLUMN O O B-TABLE O O O B-COLUMN O O B-COLUMN I-COLUMN I-COLUMN O O B-TABLE O


Question: List down at least five full names of superheroes with blue eyes.

SELECT T1.superhero_name FROM superhero AS T1 INNER JOIN colour AS T2 ON T1.eye_colour_id = T2.id WHERE T2.colour = 'Blue' LIMIT 5

List down at least five full names of superheroes with blue eyes .

O O O O O O B-COLUMN O B-TABLE O B-VALUE B-COLUMN O


Question: How many income generated by Grant Gilmour?

SELECT T2.amount FROM member AS T1 INNER JOIN income AS T2 ON T1.member_id = T2.link_to_member WHERE T1.first_name = 'Grant' AND T1.last_name = 'Gilmour'

How many income generated by Grant Gilmour ?


Question: Find all the customer last names that do not have invoice totals larger than 20.

SELECT LastName FROM CUSTOMER EXCEPT SELECT T1.LastName FROM CUSTOMER AS T1 JOIN Invoice AS T2 ON T1.CustomerId  =  T2.CustomerId WHERE T2.total  >  20

Find all the customer last names that do not have invoice totals larger than 20 .

O O O B-TABLE B-COLUMN I-COLUMN O O O O B-TABLE B-COLUMN O O B-VALUE O


Question: What is the name, rating, and age for every sailor? And order them by rating and age.

SELECT name ,  rating ,  age FROM Sailors ORDER BY rating ,  age

What is the name , rating , and age for every sailor ? And order them by rating and age .

O O B-COLUMN O O O O B-TABLE O O B-COLUMN O O O O O O O O O O


Question: Which title is the winner of Best International TV Series in 2017?

SELECT T2.title FROM Award AS T1 INNER JOIN Episode AS T2 ON T1.episode_id = T2.episode_id WHERE T1.award = 'Best International TV Series' AND SUBSTR(T1.year, 1, 4) = '2017';

Which title is the winner of Best International TV Series in 2017 ?


Question: Please list the website purchasing links of the vendors from whom the product Hex Nut 5 can be purchased.

SELECT T3.PurchasingWebServiceURL FROM ProductVendor AS T1 INNER JOIN Product AS T2 ON T1.ProductID = T2.ProductID INNER JOIN Vendor AS T3 ON T1.BusinessEntityID = T3.BusinessEntityID WHERE T2.Name = 'Hex Nut 5'

Please list the website purchasing links of the vendors from whom the product Hex Nut 5 can be purchased .

O O O O B-COLUMN I-COLUMN O O B-TABLE O O O B-TABLE B-VALUE I-VALUE I-VALUE O O O O


Question: What are the names of the customers who bought product "food" at least once?

SELECT T1.customer_name FROM customers AS T1 JOIN orders AS T2 JOIN order_items AS T3 JOIN products AS T4 ON T1.customer_id = T2.customer_id AND T2.order_id = T3.order_id AND T3.product_id = T4.product_id WHERE T4.product_name = "food" GROUP BY T1.customer_id HAVING count(*)  >=  1

What are the names of the customers who bought product " food " at least once ?


Question: How many players who were drafted by the Toronto Maple Leafs have played over 300 games in their first 7 years of the NHL career?

SELECT COUNT(ELITEID) FROM PlayerInfo WHERE overallby = 'Toronto Maple Leafs' AND sum_7yr_GP > 300

How many players who were drafted by the Toronto Maple Leafs have played over 300 games in their first 7 years of the NHL career ?

O O B-TABLE O O O O O B-VALUE I-VALUE I-VALUE O O B-COLUMN B-VALUE O O O B-COLUMN I-COLUMN I-COLUMN O O O O O


Question: Show the name of technicians aged either 36 or 37

SELECT Name FROM technician WHERE Age  =  36 OR Age  =  37

O O B-COLUMN O B-TABLE B-COLUMN O B-VALUE O B-VALUE


Question: Find all the ids and dates of the logs for the problem whose id is 10.

SELECT problem_log_id ,  log_entry_date FROM problem_log WHERE problem_id = 10

Find all the ids and dates of the logs for the problem whose i d is 10 .

O O O B-COLUMN O B-COLUMN O O B-TABLE O O B-COLUMN O B-COLUMN I-COLUMN O B-VALUE O


Question: What was the original price of Xerox 1952 ordered by Aimee Bixby on 2014/9/10?

SELECT DISTINCT T2.Sales / (1 - T2.Discount) FROM people AS T1 INNER JOIN central_superstore AS T2 ON T1.`Customer ID` = T2.`Customer ID` INNER JOIN product AS T3 ON T3.`Product ID` = T2.`Product ID` WHERE T1.`Customer Name` = 'Aimee Bixby' AND T3.`Product Name` = 'Xerox 1952' AND T2.`Order Date` = '2014-09-10'

What was the original price of Xerox 1952 ordered by Aimee Bixby on 2014/9/10 ?

O O O O O O B-VALUE I-VALUE B-COLUMN O B-VALUE I-VALUE O B-VALUE O


Question: display the employee ID for each employee and the date on which he ended his previous job.

SELECT employee_id ,  MAX(end_date) FROM job_history GROUP BY employee_id

display the employee ID for each employee and the date on which he ended his previous job .

O O B-COLUMN I-COLUMN O O O O O B-COLUMN O O O O O O B-TABLE O


Question: Among the molecules with element Calcium, are they mostly carcinogenic or non carcinogenic?

SELECT T2.label FROM atom AS T1 INNER JOIN molecule AS T2 ON T1.molecule_id = T2.molecule_id WHERE T1.element = 'ca' GROUP BY T2.label ORDER BY COUNT(T2.label) DESC LIMIT 1

Among the molecules with element Calcium , are they mostly carcinogenic or non carcinogenic ?

O O B-TABLE O B-COLUMN B-VALUE O O O O O O O O O


Question: List all employees who are at the maximum level in their job designation.

SELECT T1.fname, T1.lname FROM employee AS T1 INNER JOIN jobs AS T2 ON T1.job_id = T2.job_id WHERE T1.job_lvl = T2.max_lvl

List all employees who are at the maximum level in their job designation .

O O B-TABLE O O O O B-COLUMN B-COLUMN O O B-TABLE O O


Question: Which player became the man of the series in the year 2012? Give the name and country of this player.

SELECT T2.Player_Name, T3.Country_Name FROM Season AS T1 INNER JOIN Player AS T2 ON T1.Man_of_the_Series = T2.Player_Id INNER JOIN Country AS T3 ON T2.Country_Name = T3.Country_Id WHERE T1.Season_Year = 2012

Which player became the man of the series in the year 2012 ? Give the name and country of this player .

O B-TABLE O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN O O B-COLUMN B-VALUE O O O B-COLUMN O B-COLUMN O O B-COLUMN O


Question: display the department id and the total salary for those departments which contains at least two employees.

SELECT department_id ,  SUM(salary) FROM employees GROUP BY department_id HAVING count(*)  >=  2

display the department i d and the total salary for those departments which contains at least two employees .

O O B-COLUMN I-COLUMN I-COLUMN O O O B-COLUMN O O O O O O O B-VALUE B-TABLE O


Question: How many superheroes are published by Marvel Comics?

SELECT COUNT(T1.id) FROM superhero AS T1 INNER JOIN publisher AS T2 ON T1.publisher_id = T2.id WHERE T2.publisher_name = 'Marvel Comics'

How many superheroes are published by Marvel Comics ?

O O B-TABLE O B-TABLE O B-VALUE I-VALUE O


Question: Provide the full name and birth date of the legislator with a contact form of http://www.brown.senate.gov/contact/.

SELECT T1.official_full_name, T1.birthday_bio FROM current AS T1 INNER JOIN `current-terms` AS T2 ON T1.bioguide_id = T2.bioguide WHERE T2.contact_form = 'http://www.brown.senate.gov/contact/'

O O B-COLUMN O O O O B-COLUMN B-TABLE O O O O O O O


Question: State the headquarter of the truck which completed shipment no.1045.

SELECT T1.make FROM truck AS T1 INNER JOIN shipment AS T2 ON T1.truck_id = T2.truck_id WHERE T2.ship_id = 1045

State the headquarter of the truck which completed shipment no.1045 .

B-COLUMN O O O O B-TABLE O O B-TABLE B-VALUE O


Question: How many reservations for each boat did the sailors with an id greater than 1 make?

SELECT bid ,  count(*) FROM Reserves WHERE sid  >  1 GROUP BY bid

How many reservations for each boat did the sailors with an i d greater than 1 make ?

O O B-TABLE O O O O O O O O B-COLUMN I-COLUMN O O B-VALUE O O


Question: Which city does the address 1623 Kingstown Drive belong to?

SELECT T1.city FROM city AS T1 INNER JOIN address AS T2 ON T2.city_id = T1.city_id WHERE T2.address = '1623 Kingstown Drive'

Which city does the address 1623 Kingstown Drive belong to ?

O B-TABLE O O B-COLUMN B-VALUE I-VALUE I-VALUE O O O


Question: How many critics were given to the movie that got the most movie popularity number.

SELECT COUNT(T1.critic) FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id WHERE T2.movie_popularity = ( SELECT MAX(movie_popularity) FROM movies )

How many critics were given to the movie that got the most movie popularity number .


Question: What is the type of vocals that the band member with the last name "Heilo" played the most?

SELECT TYPE FROM vocals AS T1 JOIN band AS T2 ON T1.bandmate  =  T2.id WHERE lastname  =  "Heilo" GROUP BY TYPE ORDER BY count(*) DESC LIMIT 1

What is the type of vocals that the band member with the last name " Heilo " played the most ?

O O O B-COLUMN O B-TABLE O O B-TABLE O O O B-COLUMN I-COLUMN O B-COLUMN O O O O O


Question: Find the number of employees who do not have clearance in Mars .

select count(*) from employee where employeeid not in ( select t2.employeeid from has_clearance as t1 join employee as t2 on t1.employee = t2.employeeid join planet as t3 on t1.planet = t3.planetid where t3.name = "mars" );

O O O O B-TABLE O O O B-TABLE I-TABLE O B-COLUMN O


Question: How many umpires are from South Africa?

SELECT SUM(CASE WHEN T1.Country_Name = 'South Africa' THEN 1 ELSE 0 END) FROM Country AS T1 INNER JOIN Umpire AS T2 ON T1.Country_ID = T2.Umpire_Country

How many umpires are from South Africa ?


Question: For the donation of the project 'Awesome Audiobooks Make Avid Readers', what was the percentage of the tip in the total amount?

SELECT CAST(SUM(T2.donation_optional_support) AS REAL) * 100 / SUM(T2.donation_total) FROM essays AS T1 INNER JOIN donations AS T2 ON T1.projectid = T2.projectid WHERE T1.title LIKE 'Awesome Audiobooks Make Avid Readers'

For the donation of the project ' Awesome Audiobooks Make Avid Readers ' , what was the percentage of the tip in the total amount ?

O O O B-TABLE O B-COLUMN O B-TABLE O O O O O O O O O O O O O O O O O O


Question: Find the name, city, and country of the airport that has the highest latitude.

SELECT name ,  city ,  country FROM airports ORDER BY elevation DESC LIMIT 1

Find the name , city , and country of the airport that has the highest latitude .

O O B-COLUMN I-COLUMN O O O O B-COLUMN I-COLUMN O O O O O O O


Question: List the names of regions in alphabetical order.

SELECT Name FROM region ORDER BY Name ASC

List the names of regions in alphabetical order .


Question: From the cases where the subject are male, list the case number and the location and subject status.

SELECT T1.case_number, T1.location, T1.subject_statuses FROM incidents AS T1 INNER JOIN subjects AS T2 ON T1.case_number = T2.case_number WHERE T2.gender = 'M'

From the cases where the subject are male , list the case number and the location and subject status .

O O O O O O O B-VALUE O O O B-COLUMN I-COLUMN O O B-COLUMN O B-TABLE B-COLUMN O


Question: List the procedures received by Emmy Waelchi.

SELECT T2.DESCRIPTION FROM patients AS T1 INNER JOIN procedures AS T2 ON T1.patient = T2.PATIENT WHERE T1.first = 'Emmy' AND T1.last = 'Waelchi'

List the procedures received by Emmy Waelchi .

B-COLUMN O B-TABLE O O B-VALUE B-VALUE O


Question: What are the names of the workshop groups that have bookings with status code "stop"?

SELECT T2.Store_Name FROM Bookings AS T1 JOIN Drama_Workshop_Groups AS T2 ON T1.Workshop_Group_ID  =  T2.Workshop_Group_ID WHERE T1.Status_Code  =  "stop"

What are the names of the workshop groups that have bookings with status code " stop " ?

O O O B-COLUMN O O O O B-COLUMN O B-COLUMN O O O O O B-TABLE I-TABLE


Question: Which products by Plutzer Lebensmittelgromrkte AG were discontinued and what are their price?

SELECT T1.UnitPrice FROM Products AS T1 INNER JOIN Suppliers AS T2 ON T1.SupplierID = T2.SupplierID WHERE T2.CompanyName = 'Plutzer Lebensmittelgromrkte AG' AND T1.Discontinued = 1

Which products by Plutzer Lebensmittelgromrkte AG were discontinued and what are their price ?

O O B-TABLE O O O O B-COLUMN I-COLUMN I-COLUMN I-COLUMN B-COLUMN O O


Question: Find the captain rank that has some captains in both Cutter and Armed schooner classes.

SELECT rank FROM captain WHERE CLASS  =  'Cutter' INTERSECT SELECT rank FROM captain WHERE CLASS  =  'Armed schooner'

Find the captain rank that has some captains in both Cutter and Armed schooner classes .

O O B-TABLE B-COLUMN O O O O O O B-VALUE O B-VALUE I-VALUE B-COLUMN O


Question: What are the names of players from the club managed by Sam Allardyce?

SELECT T2.Name FROM club AS T1 JOIN player AS T2 ON T1.Club_ID  =  T2.Club_ID WHERE T1.Manager  =  "Sam Allardyce"

What are the names of players from the club managed by Sam Allardyce ?

O O O B-COLUMN O B-TABLE O O B-TABLE B-COLUMN O B-COLUMN I-COLUMN O


Question: Identify the number of posts that have been viewed over 35000 times but have received no comments from other users.

SELECT COUNT(Id) FROM posts WHERE ViewCount > 35000 AND CommentCount = 0

Identify the number of posts that have been viewed over 35000 times but have received no comments from other users .

O O O O B-TABLE O O O B-COLUMN O B-VALUE O O O O O B-COLUMN O O O O


Question: How many of the first 60,000 customers from the place with the highest average income per month have sent a true response to the incentive mailing sent by the marketing department?

SELECT COUNT(T1.ID) FROM Customers AS T1 INNER JOIN Mailings1_2 AS T2 ON T1.ID = T2.REFID INNER JOIN Demog AS T3 ON T1.GEOID = T3.GEOID WHERE T2.RESPONSE = 'true' ORDER BY T3.INCOME_K DESC LIMIT 1

How many of the first 60,000 customers from the place with the highest average income per month have sent a true response to the incentive mailing sent by the marketing department ?

O B-COLUMN I-COLUMN O B-COLUMN O B-COLUMN I-COLUMN O O O O O O O O O O O O O O O O O O O O O O O O


Question: How many apartment bookings are there in total?

How many apartment bookings are there in total ?


Question: find the number of medicines offered by each trade.

SELECT trade_name ,  count(*) FROM medicine GROUP BY trade_name

find the number of medicines offered by each trade .


Question: Give the songs included in volumes that have more than 1 week on top.

SELECT Song FROM volume WHERE Weeks_on_Top  >  1

Give the songs included in volumes that have more than 1 week on top .

O O B-COLUMN O O B-TABLE O O O O B-VALUE B-COLUMN I-COLUMN I-COLUMN O


Question: List all every engineer's first name, last name, details and coresponding skill description.

SELECT T1.first_name ,  T1.last_name ,  T1.other_details ,  T3.skill_description FROM Maintenance_Engineers AS T1 JOIN Engineer_Skills AS T2 ON T1.engineer_id  =  T2.engineer_id JOIN Skills AS T3 ON T2.skill_id  =  T3.skill_id

List all every engineer 's first name , last name , details and coresponding skill description .

O O O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN I-COLUMN O B-COLUMN O O B-TABLE B-COLUMN O


Question: How many people were not born in Connecticut, USA?

SELECT COUNT(name) FROM Person WHERE birth_region != 'Connecticut' AND birth_country != 'USA';

How many people were not born in Connecticut , USA ?

O O B-TABLE O O B-COLUMN O B-VALUE O B-VALUE O


Question: Find the average height of the players who belong to the college called 'Yale University'.

SELECT avg(T1.height) FROM player AS T1 JOIN player_college AS T2 ON T1.player_id  =  T2.player_id JOIN college AS T3 ON T3.college_id  =  T2.college_id WHERE T3.name_full  =  'Yale University';

Find the average height of the players who belong to the college called ' Yale University ' .

O O O B-COLUMN O O B-TABLE O O O O B-TABLE O O B-VALUE I-VALUE O O


Question: List the person who owns a distinguish credt card.

SELECT T3.FirstName, T3.LastName FROM CreditCard AS T1 INNER JOIN PersonCreditCard AS T2 ON T1.CreditCardID = T2.CreditCardID INNER JOIN Person AS T3 ON T2.BusinessEntityID = T3.BusinessEntityID WHERE T1.CardType = 'Distinguish'

List the person who owns a distinguish credt card .

B-COLUMN O B-TABLE O O O B-VALUE B-TABLE B-COLUMN O


Question: List in alphabetic order the names of pilots whose age is greater than some pilots having plane Piper Cub.

SELECT pilot_name FROM pilotskills WHERE age  >  (SELECT min(age) FROM pilotskills WHERE plane_name  =  'Piper Cub') ORDER BY pilot_name

List in alphabetic order the names of pilots whose age is greater than some pilots having plane Piper Cub .

O O O O O B-COLUMN O B-COLUMN O B-COLUMN O O O O B-TABLE O B-COLUMN B-VALUE I-VALUE O


Question: Which different county has the most number of closed schools? Please provide the name of each school as well as the closure date.

SELECT DISTINCT County, School, ClosedDate FROM schools WHERE County = ( SELECT County FROM schools WHERE StatusType = 'Closed' GROUP BY County ORDER BY COUNT(School) DESC LIMIT 1 ) AND StatusType = 'Closed' AND school IS NOT NULL

Which different county has the most number of closed schools ? Please provide the name of each school as well as the closure date .

O O B-COLUMN O O O O O B-VALUE B-TABLE O O O O O O O B-COLUMN O O O O B-COLUMN I-COLUMN O


Question: Between 2011 to 2016, in which countries can you find the universities where at least 50% of its students are international students?

SELECT DISTINCT T3.country_name FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id INNER JOIN country AS T3 ON T3.id = T1.country_id WHERE T2.pct_international_students > 50 AND T2.year BETWEEN 2011 AND 2016

Between 2011 to 2016 , in which countries can you find the universities where at least 50 % of its students are international students ?

O O O B-TABLE O B-COLUMN O O O O B-TABLE I-TABLE O O O O O O O O O O O O O


Question: How many players have rank of the year smaller than 3?

SELECT count(*) FROM player WHERE Rank_of_the_year  <=  3

How many players have rank of the year smaller than 3 ?

O O B-TABLE O B-COLUMN I-COLUMN I-COLUMN I-COLUMN O O B-VALUE O


Question: How many locations are listed in the database?

How many locations are listed in the database ?


Question: What films did Burt Dukakis got star in?

SELECT T3.title FROM film_actor AS T1 INNER JOIN actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T1.film_id = T3.film_id WHERE T2.first_name = 'BURT' AND T2.last_name = 'DUKAKIS'

What films did Burt Dukakis got star in ?


Question: Provide the ID of the university with the highest percentage of female students in 2012.

SELECT university_id FROM university_year WHERE year = 2012 ORDER BY pct_female_students DESC LIMIT 1

Provide the ID of the university with the highest percentage of female students in 2012 .

O O B-COLUMN O O B-COLUMN O O O B-COLUMN O B-COLUMN I-COLUMN O B-VALUE O


Question: What are the names of all movies that were created after the most recent Steven Spielberg film?

SELECT title FROM Movie WHERE YEAR  >  (SELECT max(YEAR) FROM Movie WHERE director  =  "Steven Spielberg")

What are the names of all movies that were created after the most recent Steven Spielberg film ?

O O O O O O B-TABLE O O O O O O O B-COLUMN I-COLUMN O O


Question: Provide the total number of the male users that use OPPO as their phone brand.

SELECT COUNT(T1.device_id) FROM gender_age AS T1 INNER JOIN phone_brand_device_model2 AS T2 ON T1.device_id = T2.device_id WHERE T2.phone_brand = 'OPPO' AND T1.gender = 'M'

Provide the total number of the male users that use OPPO as their phone brand .

O O O O B-TABLE O B-TABLE O O B-VALUE O O B-COLUMN O B-VALUE O


Question: State the number of public magnet schools in New York Manhattan.

SELECT COUNT(schoolid) FROM projects WHERE school_county = 'New York (Manhattan)' AND school_magnet = 't'

State the number of public magnet schools in New York Manhattan .

O O O O O B-COLUMN B-COLUMN O B-VALUE I-VALUE I-VALUE O


Question: What is the title of the book written by Plato has price lower than the average sale price of all books?

SELECT T1.title FROM Book AS T1 JOIN Author_book AS T2 ON T1.isbn  =  T2.isbn JOIN Author AS T3 ON T2.Author  =  T3.idAuthor WHERE T3.name  =  "Plato" AND T1.saleprice  <  (SELECT avg(saleprice) FROM Book)

What is the title of the book written by Plato has price lower than the average sale price of all books ?

O O B-TABLE O B-TABLE O O B-TABLE O O B-COLUMN O O O O B-COLUMN O O O O O O


Question: What are the atoms that can bond with the atom that has the element lead?

SELECT T2.atom_id, T2.atom_id2 FROM atom AS T1 INNER JOIN connected AS T2 ON T1.atom_id = T2.atom_id WHERE T1.element = 'pb'

What are the atoms that can bond with the atom that has the element lead ?

O O O B-TABLE O O O O O B-COLUMN O O O B-COLUMN O O


Question: What is the percentage of the cases involved more than 3 officers from year 2010 to 2015?

SELECT CAST(SUM(IIF(officer_count > 3, 1, 0)) AS REAL) * 100 / COUNT(case_number) FROM incidents WHERE STRFTIME('%Y', date) BETWEEN '2010' AND '2015'

What is the percentage of the cases involved more than 3 officers from year 2010 to 2015 ?

O O O O O O B-COLUMN O O O B-VALUE B-COLUMN O B-VALUE B-VALUE O B-VALUE O


Question: Find the first and last name of all the students of age 18 who have vice president votes.

SELECT DISTINCT T1.Fname ,  T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.VICE_President_VOTE WHERE T1.age  =  18

Find the first and last name of all the students of age 18 who have vice president votes .

O O B-COLUMN O B-COLUMN I-COLUMN O O O B-TABLE O B-COLUMN B-VALUE O O B-COLUMN I-COLUMN B-TABLE O


Question: Show all video games and their types in the order of their names.

SELECT gname ,  gtype FROM Video_games ORDER BY gname

Show all video games and their types in the order of their names .

O O B-TABLE I-TABLE O O B-COLUMN O O O O O B-COLUMN O


Question: Provide the average elevation of the cities with alias Amherst.

SELECT AVG(T2.elevation) FROM alias AS T1 INNER JOIN zip_data AS T2 ON T1.zip_code = T2.zip_code WHERE T1.alias = 'Amherst'

Provide the average elevation of the cities with alias Amherst .

O O O B-COLUMN O O O O B-TABLE B-VALUE O


Question: What are all the section titles of the document named "David CV"?

SELECT t2.section_title FROM documents AS t1 JOIN document_sections AS t2 ON t1.document_code  =  t2.document_code WHERE t1.document_name  =  "David CV"

What are all the section titles of the document named " David CV " ?

O O O O B-COLUMN I-COLUMN O O B-TABLE B-COLUMN O B-COLUMN I-COLUMN O O


Question: What is the air carrier's description of the cancelled flights?

SELECT T1.Description FROM `Air Carriers` AS T1 INNER JOIN Airlines AS T2 ON T1.Code = T2.OP_CARRIER_AIRLINE_ID WHERE T2.CANCELLED = 1 GROUP BY T1.Description

What is the air carrier 's description of the cancelled flights ?

O O O B-TABLE I-TABLE I-TABLE B-COLUMN O O B-COLUMN O O


Question: How many airports haven't the pilot 'Thompson' driven an aircraft?

SELECT count(*) FROM airport WHERE id NOT IN ( SELECT airport_id FROM flight WHERE pilot  =  'Thompson' );

How many airports have n't the pilot ' Thompson ' driven an aircraft ?

O O B-TABLE O O O B-COLUMN O B-VALUE O O O O O


Question: What are the ids and names of all customers?

SELECT customer_id ,  customer_name FROM Customers

What are the ids and names of all customers ?


Question: Which students have gone through any event? List the students' biographical data and event date.

SELECT T1.bio_data ,  T2.event_date FROM Students AS T1 JOIN Student_Events AS T2 ON T1.student_id  =  T2.student_id

Which students have gone through any event ? List the students ' biographical data and event date .

O B-TABLE O O O O O O O O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN I-COLUMN O


Question: What is the eligible free or reduced price meal rate for the top 5 schools in grades 1-12 with the highest free or reduced price meal count of the schools with the ownership code 66?

SELECT CAST(T1.`FRPM Count (K-12)` AS REAL) / T1.`Enrollment (K-12)` FROM frpm AS T1 INNER JOIN schools AS T2 ON T1.CDSCode = T2.CDSCode WHERE T2.SOC = 66 ORDER BY T1.`FRPM Count (K-12)` DESC LIMIT 5

What is the eligible free or reduced price meal rate for the top 5 schools in grades 1 - 12 with the highest free or reduced price meal count of the schools with the ownership code 66 ?

O O O O O O O O O O O O O O B-TABLE O O B-COLUMN I-COLUMN I-COLUMN O O O O O O O B-COLUMN I-COLUMN O O O O O O B-COLUMN B-VALUE O


Question: What is the count of states with college students playing in the mid position but not as goalies?

SELECT COUNT(*) FROM (SELECT T1.state FROM college AS T1 JOIN tryout AS T2 ON T1.cName  =  T2.cName WHERE T2.pPos  =  'mid' EXCEPT SELECT T1.state FROM college AS T1 JOIN tryout AS T2 ON T1.cName  =  T2.cName WHERE T2.pPos  =  'goalie')

What is the count of states with college students playing in the mid position but not as goalies ?

O O B-TABLE O O B-COLUMN O B-TABLE O O O O O O O O O O O


Question: Which apartments have bookings with status code "Confirmed"? Return their apartment numbers.

SELECT DISTINCT T2.apt_number FROM Apartment_Bookings AS T1 JOIN Apartments AS T2 ON T1.apt_id  =  T2.apt_id WHERE T1.booking_status_code  =  "Confirmed"

Which apartments have bookings with status code " Confirmed " ? Return their apartment numbers .

O B-TABLE O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN O O O O B-COLUMN B-COLUMN O


Question: What are the famous titles of artists who have not only had volumes that spent more than 2 weeks on top but also volumes that spent less than 2 weeks on top?

SELECT T1.Famous_Title FROM artist AS T1 JOIN volume AS T2 ON T1.Artist_ID  =  T2.Artist_ID WHERE T2.Weeks_on_Top  >  2 INTERSECT SELECT T1.Famous_Title FROM artist AS T1 JOIN volume AS T2 ON T1.Artist_ID  =  T2.Artist_ID WHERE T2.Weeks_on_Top  <  2

What are the famous titles of artists who have not only had volumes that spent more than 2 weeks on top but also volumes that spent less than 2 weeks on top ?

O O O B-TABLE I-TABLE O O B-COLUMN O O O O O O O B-TABLE O O O O O O O O O O O O O O O O O


Question: List all the withdrawals in cash transactions that the client with the id 3356 makes.

SELECT T4.trans_id FROM client AS T1 INNER JOIN disp AS T2 ON T1.client_id = T2.client_id INNER JOIN account AS T3 ON T2.account_id = T3.account_id INNER JOIN trans AS T4 ON T3.account_id = T4.account_id WHERE T1.client_id = 3356 AND T4.operation = 'VYBER'

List all the withdrawals in cash transactions that the client with the i d 3356 makes .

O O O O O O B-COLUMN O O B-TABLE O O B-COLUMN I-COLUMN B-VALUE O O


Question: What are the forenames and surnames of all unique drivers who had a lap time of less than 93000 milliseconds?

SELECT DISTINCT T1.forename ,  T1.surname FROM drivers AS T1 JOIN laptimes AS T2 ON T1.driverid = T2.driverid WHERE T2.milliseconds < 93000

What are the forenames and surnames of all unique drivers who had a lap time of less than 93000 milliseconds ?

O O O B-COLUMN O B-COLUMN O O O B-TABLE O O O B-TABLE I-TABLE O O O B-VALUE B-COLUMN O


Question: Which crytocurrency was traded in the highest value on 2016/1/8?

SELECT T1.name FROM coins AS T1 INNER JOIN historical AS T2 ON T1.id = T2.coin_id WHERE T2.date = '2016-01-08' AND T2.volume_24h = ( SELECT MAX(volume_24h) FROM historical WHERE date = '2016-01-08' )

Which crytocurrency was traded in the highest value on 2016/1/8 ?


Question: What are the names of wines, sorted by price ascending?

SELECT DISTINCT Name FROM WINE ORDER BY price

What are the names of wines , sorted by price ascending ?

O O O B-COLUMN O B-TABLE O O O B-COLUMN O O


Question: In which country can I find the circuit with the highest altitude?

SELECT country FROM circuits ORDER BY alt DESC LIMIT 1

In which country can I find the circuit with the highest altitude ?

O O B-COLUMN O O O O B-TABLE O O O B-COLUMN O


Question: What type of transaction was made with the only yellow product, size 62 and with a minimum inventory stock of 500 units?

SELECT DISTINCT T2.TransactionType FROM Product AS T1 INNER JOIN TransactionHistory AS T2 ON T1.ProductID = T2.ProductID WHERE T1.Size = 62 AND T1.Color = 'Yellow' AND T1.SafetyStockLevel = 500

What type of transaction was made with the only yellow product , size 62 and with a minimum inventory stock of 500 units ?

O B-COLUMN I-COLUMN I-COLUMN O O O O O B-VALUE B-TABLE O B-COLUMN B-VALUE O O O O O B-COLUMN O B-VALUE O O


Question: What are the names of products produced by both Creative Labs and Sony?

SELECT T1.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer  =  T2.code WHERE T2.name  =  'Creative Labs' INTERSECT SELECT T1.name FROM products AS T1 JOIN manufacturers AS T2 ON T1.Manufacturer  =  T2.code WHERE T2.name  =  'Sony'

What are the names of products produced by both Creative Labs and Sony ?

O O O B-COLUMN O B-TABLE O O O B-VALUE I-VALUE O B-VALUE O


Question: Which brand of root beer did Jayne Collins give the lowest rating?

SELECT T3.BrandName FROM customers AS T1 INNER JOIN rootbeerreview AS T2 ON T1.CustomerID = T2.CustomerID INNER JOIN rootbeerbrand AS T3 ON T2.BrandID = T3.BrandID WHERE T1.First = 'Jayne' AND T1.Last = 'Collins' AND T2.StarRating = 1

Which brand of root beer did Jayne Collins give the lowest rating ?

O B-COLUMN O B-TABLE I-TABLE O B-VALUE B-VALUE O O O B-COLUMN O


Question: List the summary of the method "Castle.MonoRail.Framework.Test.StubViewComponentContext.RenderSection".

SELECT DISTINCT Summary FROM Method WHERE Name = 'Castle.MonoRail.Framework.Test.StubViewComponentContext.RenderSection'

List the summary of the method " Castle . MonoRail . Framework . Test . StubViewComponentContext . RenderSection " .

O O B-COLUMN O O B-TABLE O B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O O


Question: What is the language that was used most often in songs with resolution above 500?

SELECT artist_name FROM song WHERE resolution  >  500 GROUP BY languages ORDER BY count(*) DESC LIMIT 1

What is the language that was used most often in songs with resolution above 500 ?

O O O O O O O B-TABLE O O O O O B-COLUMN B-COLUMN O


Question: Find the ID of advisor of student ID 80 and state the level of courses taught by him/her.

SELECT T1.p_id_dummy, T2.courseLevel FROM advisedBy AS T1 INNER JOIN course AS T2 ON T1.p_id = T2.course_id INNER JOIN taughtBy AS T3 ON T2.course_id = T3.course_id WHERE T1.p_id = 80

Find the ID of advisor of student ID 80 and state the level of courses taught by him / her .

O O B-COLUMN O B-TABLE O O B-COLUMN B-VALUE O O O B-COLUMN O B-TABLE B-TABLE I-TABLE O O O O


Question: Find the number of students in total.


Question: How many units are being sold for item 1 when the average temperature is 83?

SELECT SUM(units) FROM weather AS T1 INNER JOIN sales_in_weather AS T2 ON T1.`date` = T2.`date` INNER JOIN relation AS T3 ON T2.store_nbr = T3.store_nbr WHERE T2.item_nbr = 1 AND T1.tavg = 83

How many units are being sold for item 1 when the average temperature is 83 ?

O O B-COLUMN O O O O B-COLUMN B-VALUE O O B-COLUMN O O B-VALUE O


Question: Provide list titles created by user who are eligible for trial when he created the list.

SELECT DISTINCT T2.list_title FROM lists_users AS T1 INNER JOIN lists AS T2 ON T1.list_id = T2.list_id WHERE T1.user_eligible_for_trial = 1

Provide list titles created by user who are eligible for trial when he created the list .

O O B-COLUMN B-TABLE O O O O O O B-TABLE O O O O O O


Question: Who had to take Clopidogrel 75 MG Oral Tablet for over 10 years?

SELECT T1.first, T1.last FROM patients AS T1 INNER JOIN medications AS T2 ON T1.patient = T2.PATIENT WHERE T2.DESCRIPTION = 'Clopidogrel 75 MG Oral Tablet' AND strftime('%Y', T2.STOP) - strftime('%Y', T2.START) > 10

Who had to take Clopidogrel 75 MG Oral Tablet for over 10 years ?

O O O O B-VALUE I-VALUE I-VALUE I-VALUE O O O B-VALUE B-VALUE O


Question: Who is the author of the book The Mystery in the Rocky Mountains?

SELECT T3.author_name FROM book AS T1 INNER JOIN book_author AS T2 ON T1.book_id = T2.book_id INNER JOIN author AS T3 ON T3.author_id = T2.author_id WHERE T1.title = 'The Mystery in the Rocky Mountains'

Who is the author of the book The Mystery in the Rocky Mountains ?

O O O B-TABLE O O B-TABLE B-VALUE I-VALUE I-VALUE I-VALUE I-VALUE I-VALUE O


Question: How many orders were shipped via Federal Shipping?

SELECT COUNT(T1.OrderID) FROM Orders AS T1 INNER JOIN Shippers AS T2 ON T1.ShipVia = T2.ShipperID WHERE T2.CompanyName = 'Federal Shipping' AND T1.ShipVia = 3

How many orders were shipped via Federal Shipping ?

O O B-TABLE O B-COLUMN B-COLUMN B-VALUE I-VALUE O


Question: Find the ids and first names of the 3 teachers that have the most number of assessment notes?

SELECT T1.teacher_id ,  T2.first_name FROM Assessment_Notes AS T1 JOIN Teachers AS T2 ON T1.teacher_id  =  T2.teacher_id GROUP BY T1.teacher_id ORDER BY count(*) DESC LIMIT 3

Find the ids and first names of the 3 teachers that have the most number of assessment notes ?

O O B-COLUMN O B-COLUMN I-COLUMN O O O B-TABLE O O O O O O B-TABLE I-TABLE O


Question: What is the payment method of the customer that has purchased the least quantity of items?

SELECT t1.payment_method FROM customers AS t1 JOIN customer_orders AS t2 ON t1.customer_id  =  t2.customer_id JOIN order_items AS t3 ON t2.order_id  =  t3.order_id GROUP BY t1.customer_name ORDER BY sum(t3.order_quantity) LIMIT 1

What is the payment method of the customer that has purchased the least quantity of items ?

O O O B-COLUMN O O O O O O B-COLUMN O B-TABLE O B-TABLE O O


Question: What is the total number of students in the school?

What is the total number of students in the school ?


Question: Write the full name of the club member with the position of 'Secretary' and list which college the club member belongs to.

SELECT T1.first_name, T1.last_name, college FROM member AS T1 INNER JOIN major AS T2 ON T2.major_id = T1.link_to_major WHERE T1.position = 'Secretary'

Write the full name of the club member with the position of ' Secretary ' and list which college the club member belongs to .

O O O B-COLUMN O O O B-TABLE O O B-COLUMN O O B-VALUE O O O O B-COLUMN O O O O O O


Question: Give the case number and coordinates of the places where child abduction is reported.

SELECT T1.case_number, T1.latitude, T1.longitude FROM Crime AS T1 INNER JOIN IUCR AS T2 ON T2.iucr_no = T1.iucr_no WHERE T2.secondary_description = 'CHILD ABDUCTION'

Give the case number and coordinates of the places where child abduction is reported .

O O B-COLUMN I-COLUMN O O O O O O B-VALUE I-VALUE O O O


Question: What is the percentage of severe cases that are related to sexual assault?

SELECT CAST(SUM(CASE WHEN primary_description = 'CRIM SEXUAL ASSAULT' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) FROM IUCR WHERE index_code = 'I'

What is the percentage of severe cases that are related to sexual assault ?


Question: What is the average absent month for a unemployed male students?

SELECT AVG(T2.month) AS avg FROM unemployed AS T1 INNER JOIN longest_absense_from_school AS T2 ON T2.name = T1.name INNER JOIN male AS T3 ON T3.name = T2.name

What is the average absent month for a unemployed male students ?

O O O O B-TABLE B-COLUMN O O B-TABLE B-TABLE O O


Question: In "A Lover's Complaint", what is the description of Act 1, Scene 1?

SELECT T2.Description FROM works AS T1 INNER JOIN chapters AS T2 ON T1.id = T2.work_id WHERE T2.Act = 1 AND T2.Scene = 1 AND T1.Title = 'A Lover''s Complaint'

In " A Lover 's Complaint " , what is the description of Act 1 , Scene 1 ?

O O B-VALUE I-VALUE I-VALUE I-VALUE O O O O O B-COLUMN O B-COLUMN B-VALUE O B-COLUMN B-VALUE O


Question: Which region does Hoffman Estates belong to?

SELECT T2.RegionDescription FROM Territories AS T1 INNER JOIN Region AS T2 ON T1.RegionID = T2.RegionID WHERE T1.TerritoryDescription = 'Hoffman Estates'

Which region does Hoffman Estates belong to ?


Question: How many legislators have an Instagram account?

SELECT COUNT(*) FROM `social-media` WHERE instagram IS NOT NULL AND instagram <> ''

How many legislators have an Instagram account ?


Question: State the prevalence rate of condition no. 368581000119106.

SELECT DISTINCT T1."PREVALENCE RATE" FROM all_prevalences AS T1 INNER JOIN conditions AS T2 ON lower(T1.ITEM) = lower(T2.DESCRIPTION) WHERE T2.code = '368581000119106'

State the prevalence rate of condition no . 368581000119106 .


Question: Return the date of birth for all the guests with gender code "Male".

SELECT date_of_birth FROM Guests WHERE gender_code  =  "Male"

Return the date of birth for all the guests with gender code " Male " .

O O B-COLUMN I-COLUMN I-COLUMN O O O B-TABLE O B-COLUMN I-COLUMN O B-COLUMN O O


Question: In the non-carcinogenic molecules, how many contain chlorine atoms?

SELECT COUNT(DISTINCT T1.molecule_id) FROM molecule AS T1 INNER JOIN atom AS T2 ON T1.molecule_id = T2.molecule_id WHERE T2.element = 'cl' AND T1.label = '-'

In the non - carcinogenic molecules , how many contain chlorine atoms ?

O O O B-VALUE O B-TABLE O O O O B-VALUE B-TABLE O


Question: Give the names and scores of wines made from white grapes.

SELECT T2.Name ,   T2.Score FROM GRAPES AS T1 JOIN WINE AS T2 ON T1.Grape  =  T2.Grape WHERE T1.Color  =  "White"

Give the names and scores of wines made from white grapes .

O O B-COLUMN O B-COLUMN O B-TABLE O O B-COLUMN B-TABLE O


Question: What brand of beer has been the worst rated most times?

SELECT T1.BrandName FROM rootbeerbrand AS T1 INNER JOIN rootbeerreview AS T2 ON T2.BrandID = T1.BrandID WHERE T2.StarRating = 1 GROUP BY T1.BrandName ORDER BY COUNT(T1.BrandName) DESC LIMIT 1

What brand of beer has been the worst rated most times ?

O B-COLUMN O B-TABLE O O O O B-COLUMN O O O


Question: How many undergraduates are there in "San Jose State University" in year 2004?

SELECT sum(t1.undergraduate) FROM discipline_enrollments AS t1 JOIN campuses AS t2 ON t1.campus  =  t2.id WHERE t1.year  =  2004 AND t2.campus  =  "San Jose State University"

How many undergraduates are there in " San Jose State University " in year 2004 ?

O O B-COLUMN O O O O B-TABLE I-TABLE B-COLUMN I-COLUMN B-TABLE O B-COLUMN B-VALUE O


Question: List down the neighborhood areas of Douglas.

SELECT T2.neighborhood_name FROM Community_Area AS T1 INNER JOIN Neighborhood AS T2 ON T2.community_area_no = T1.community_area_no WHERE T1.community_area_name = 'Douglas'

List down the neighborhood areas of Douglas .


Question: Please list the top three employees with the most unused sick leave along with their position titles.

SELECT JobTitle FROM Employee ORDER BY SickLeaveHours DESC LIMIT 3

Please list the top three employees with the most unused sick leave along with their position titles .

O O O B-TABLE O B-COLUMN O O B-COLUMN O O O O O O O O O


Question: What is the name of the movie that was rated recently by user 57756708?

SELECT T2.movie_title FROM ratings AS T1 INNER JOIN movies AS T2 ON T1.movie_id = T2.movie_id WHERE T1.user_id = 57756708 ORDER BY T1.rating_timestamp_utc DESC LIMIT 1

What is the name of the movie that was rated recently by user 57756708 ?

O O O O O B-COLUMN B-VALUE O B-COLUMN O O O O O O


Question: List the region name where games reached 300000 sales and above.

SELECT DISTINCT T1.region_name FROM region AS T1 INNER JOIN region_sales AS T2 ON T1.id = T2.region_id WHERE T2.num_sales * 100000 > 300000

List the region name where games reached 300000 sales and above .

O O B-TABLE B-COLUMN O O O B-VALUE B-COLUMN O O O


Question: What is the difference in the average number of sales per day of root beer brands that contain honey and that don’t contain honey.

SELECT (CAST(SUM(CASE WHEN T1.Honey = 'TRUE' THEN 1 ELSE 0 END) AS REAL) / COUNT(DISTINCT T3.TransactionDate)) - (CAST(SUM(CASE WHEN T1.Honey <> 'TRUE' THEN 1 ELSE 0 END) AS REAL) / COUNT(DISTINCT T3.TransactionDate)) FROM rootbeerbrand AS T1 INNER JOIN rootbeer AS T2 ON T1.BrandID = T2.BrandID INNER JOIN `transaction` AS T3 ON T2.RootBeerID = T3.RootBeerID

What is the difference in the average number of sales per day of root beer brands that contain honey and that do n’t contain honey .

O O O O O O B-TABLE O O B-TABLE O O O O O O O O O O O O O O O O