richardr1126/spider-context-instruct huggingface dataset:
### Instruction:

Convert text to sql: What are the names and hours spent practicing of every student who received a yes at tryouts? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select player.pname , player.hs from player join tryout on player.pid = tryout.pid where tryout.decision = 'yes'

### Instruction:

Convert text to sql: Find the states of the colleges that have students in the tryout who played in striker position. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'striker'

### Instruction:

Convert text to sql: What are the states of the colleges where students who tried out for the striker position attend? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'striker'

### Instruction:

Convert text to sql: Find the names of the students who are in the position of striker and got a yes tryout decision. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select player.pname from player join tryout on player.pid = tryout.pid where tryout.decision = 'yes' and tryout.ppos = 'striker'

### Instruction:

Convert text to sql: What are the names of all students who successfully tried out for the position of striker? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select player.pname from player join tryout on player.pid = tryout.pid where tryout.decision = 'yes' and tryout.ppos = 'striker'

### Instruction:

Convert text to sql: Find the state of the college which player Charles is attending. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname join player on tryout.pid = player.pid where player.pname = 'Charles'

### Instruction:

Convert text to sql: In which state is the college that Charles attends? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname join player on tryout.pid = player.pid where player.pname = 'Charles'
### Instruction:

Convert text to sql: Find the average and maximum hours for the students whose tryout decision is yes. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select avg ( player.hs ) , max ( player.hs ) from player join tryout on player.pid = tryout.pid where tryout.decision = 'yes'

### Instruction:

Convert text to sql: What is the average and maximum number of hours students who made the team practiced? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select avg ( player.hs ) , max ( player.hs ) from player join tryout on player.pid = tryout.pid where tryout.decision = 'yes'

### Instruction:

Convert text to sql: Find the average hours for the students whose tryout decision is no. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select avg ( player.hs ) from player join tryout on player.pid = tryout.pid where tryout.decision = 'no'

### Instruction:

Convert text to sql: What is the average number of hours spent practicing for students who got rejected? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select avg ( player.hs ) from player join tryout on player.pid = tryout.pid where tryout.decision = 'no'

### Instruction:

Convert text to sql: What is the maximum training hours for the students whose training hours is greater than 1000 in different positions? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select max ( player.hs ) , ppos from player join tryout on player.pid = tryout.pid where player.hs > 1000 group by tryout.ppos

### Instruction:

Convert text to sql: For each position, what is the maximum number of  hours for students who spent more than 1000 hours training? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select max ( player.hs ) , ppos from player join tryout on player.pid = tryout.pid where player.hs > 1000 group by tryout.ppos

### Instruction:

Convert text to sql: Which colleges do the tryout players whose name starts with letter D go to? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select tryout.cname from tryout join player on tryout.pid = player.pid where player.pname like 'D%'
### Instruction:

Convert text to sql: Which colleges does each player with a name that starts with the letter D  who tried out go to? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select tryout.cname from tryout join player on tryout.pid = player.pid where player.pname like 'D%'

### Instruction:

Convert text to sql: Which college has any student who is a goalie and succeeded in the tryout. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from tryout where decision = 'yes' and ppos = 'goalie'

### Instruction:

Convert text to sql: What college has a student who successfully made the team in the role of a goalie? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from tryout where decision = 'yes' and ppos = 'goalie'

### Instruction:

Convert text to sql: Find the name of the tryout players who are from the college with largest size. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select player.pname from tryout join player on tryout.pid = player.pid where tryout.cname = ( select cname from college order by enr desc limit 1 )

### Instruction:

Convert text to sql: What are the names of all tryout participants who are from the largest college? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select player.pname from tryout join player on tryout.pid = player.pid where tryout.cname = ( select cname from college order by enr desc limit 1 )

### Instruction:

Convert text to sql: What is the state and enrollment of the colleges where have any students who got accepted in the tryout decision. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select distinct college.state , college.enr from college join tryout on college.cname = tryout.cname where tryout.decision = 'yes'

### Instruction:

Convert text to sql: How many students are enrolled in colleges that have student accepted during tryouts, and in which states are those colleges? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select distinct college.state , college.enr from college join tryout on college.cname = tryout.cname where tryout.decision = 'yes'
### Instruction:

Convert text to sql: Find the names of either colleges in LA with greater than 15000 size or in state AZ with less than 13000 enrollment. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from college where enr < 13000 and state = 'AZ' union select cname from college where enr > 15000 and state = 'LA'

### Instruction:

Convert text to sql: What are the names of colleges in LA that have more than 15,000 students and of colleges in AZ with less than 13,000 students? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from college where enr < 13000 and state = 'AZ' union select cname from college where enr > 15000 and state = 'LA'

### Instruction:

Convert text to sql: Find the names of schools that have some students playing in goalie and mid positions. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from tryout where ppos = 'goalie' intersect select cname from tryout where ppos = 'mid'

### Instruction:

Convert text to sql: What are the names of all schools that have students trying out for the position of goal and 'mid'-field. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from tryout where ppos = 'goalie' intersect select cname from tryout where ppos = 'mid'

### Instruction:

Convert text to sql: Find the names of states that have some college students playing in goalie and mid positions. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'goalie' intersect select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'mid'

### Instruction:

Convert text to sql: What are the names of the states that have some college students playing in the positions of goalie and mid-field? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'goalie' intersect select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'mid'
### Instruction:

Convert text to sql: How many schools have some students playing in goalie and mid positions. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( * ) from ( select cname from tryout where ppos = 'goalie' intersect select cname from tryout where ppos = 'mid' )

### Instruction:

Convert text to sql: How many schools have students playing in goalie and mid-field positions? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( * ) from ( select cname from tryout where ppos = 'goalie' intersect select cname from tryout where ppos = 'mid' )

### Instruction:

Convert text to sql: Find the names of schools that have some players in the mid position but not in the goalie position. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from tryout where ppos = 'mid' except select cname from tryout where ppos = 'goalie'

### Instruction:

Convert text to sql: What are the names of the schools with some players in the mid position but no goalies? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from tryout where ppos = 'mid' except select cname from tryout where ppos = 'goalie'

### Instruction:

Convert text to sql: Find the names of states that have some college students playing in the mid position but not in the goalie position. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'mid' except select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'goalie'

### Instruction:

Convert text to sql: What are the names of all the states with college students playing in the mid position but no goalies? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'mid' except select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'goalie'
### Instruction:

Convert text to sql: How many states that have some college students playing in the mid position but not in the goalie position. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( * ) from ( select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'mid' except select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'goalie' )

### Instruction:

Convert text to sql: What is the count of states with college students playing in the mid position but not as goalies? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( * ) from ( select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'mid' except select college.state from college join tryout on college.cname = tryout.cname where tryout.ppos = 'goalie' )

### Instruction:

Convert text to sql: Find the states where have the colleges whose enrollments are less than the largest size. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select distinct state from college where enr < ( select max ( enr ) from college )

### Instruction:

Convert text to sql: What are the states with colleges that have enrollments less than the some other college? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select distinct state from college where enr < ( select max ( enr ) from college )

### Instruction:

Convert text to sql: Find names of colleges with enrollment greater than that of some (at least one) college in the FL state. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select distinct cname from college where enr > ( select min ( enr ) from college where state = 'FL' )

### Instruction:

Convert text to sql: What are the names of the colleges that are larger than at least one college in Florida? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select distinct cname from college where enr > ( select min ( enr ) from college where state = 'FL' )
### Instruction:

Convert text to sql: Find names of all colleges whose enrollment is greater than that of all colleges in the FL state. | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from college where enr > ( select max ( enr ) from college where state = 'FL' )

### Instruction:

Convert text to sql: What are the names of all colleges with a larger enrollment than the largest college in Florida? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select cname from college where enr > ( select max ( enr ) from college where state = 'FL' )

### Instruction:

Convert text to sql: What is the total number of enrollment of schools that do not have any goalie player? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select sum ( enr ) from college where cname not in ( select cname from tryout where ppos = 'goalie' )

### Instruction:

Convert text to sql: What is the total number of students enrolled in schools without any goalies? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select sum ( enr ) from college where cname not in ( select cname from tryout where ppos = 'goalie' )

### Instruction:

Convert text to sql: What is the number of states that has some college whose enrollment is larger than the average enrollment? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( distinct state ) from college where enr > ( select avg ( enr ) from college )

### Instruction:

Convert text to sql: How many states have a college with more students than average? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( distinct state ) from college where enr > ( select avg ( enr ) from college )

### Instruction:

Convert text to sql: What is the number of states that has some colleges whose enrollment is smaller than the average enrollment? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( distinct state ) from college where enr < ( select avg ( enr ) from college )
### Instruction:

Convert text to sql: How many states have smaller colleges than average? | college : cname , state , enr | player : pid , pname , ycard , hs | tryout : pid , cname , ppos , decision | tryout.cname = college.cname | tryout.pid = player.pid | 

### Response:

select count ( distinct state ) from college where enr < ( select avg ( enr ) from college )
### Instruction:

Convert text to sql: How many devices are there? | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select count ( * ) from device

### Instruction:

Convert text to sql: Count the number of devices. | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select count ( * ) from device

### Instruction:

Convert text to sql: List the carriers of devices in ascending alphabetical order. | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select carrier from device order by carrier asc

### Instruction:

Convert text to sql: What are the different carriers for devices, listed in alphabetical order? | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select carrier from device order by carrier asc

### Instruction:

Convert text to sql: What are the carriers of devices whose software platforms are not "Android"? | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select carrier from device where software_platform != 'Android'

### Instruction:

Convert text to sql: Return the device carriers that do not have Android as their software platform. | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select carrier from device where software_platform != 'Android'

### Instruction:

Convert text to sql: What are the names of shops in ascending order of open year? | device : device_id , device , carrier , package_version , applications , software_platform | shop : shop_id , shop_name , location , open_date , open_year | stock : shop_id , device_id , quantity | stock.device_id = device.device_id | stock.shop_id = shop.shop_id | 

### Response:

select shop_name from shop order by open_year asc