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

Convert text to sql: Show the number of transaction types. | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select count ( distinct _ ) from _ | select count ( distinct transaction_type ) from financial_transactions
### Instruction:

Convert text to sql: How many different types of transactions are there? | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select count ( distinct _ ) from _ | select count ( distinct transaction_type ) from financial_transactions
### Instruction:

Convert text to sql: What is the average and total transaction amount? | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select avg ( _ ) , sum ( _ ) from _ | select avg ( transaction_amount ) , sum ( transaction_amount ) from financial_transactions
### Instruction:

Convert text to sql: Return the average transaction amount, as well as the total amount of all transactions. | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select avg ( _ ) , sum ( _ ) from _ | select avg ( transaction_amount ) , sum ( transaction_amount ) from financial_transactions
### Instruction:

Convert text to sql: Show the card type codes and the number of transactions. | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select customers_cards.card_type_code , count ( * ) from financial_transactions join customers_cards on financial_transactions.card_id = customers_cards.card_id group by customers_cards.card_type_code
### Instruction:

Convert text to sql: What are the different card types, and how many transactions have been made with each? | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select customers_cards.card_type_code , count ( * ) from financial_transactions join customers_cards on financial_transactions.card_id = customers_cards.card_id group by customers_cards.card_type_code
### Instruction:

Convert text to sql: Show the transaction type and the number of transactions. | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select transaction_type , count ( * ) from financial_transactions group by transaction_type
### Instruction:

Convert text to sql: What are the different transaction types, and how many transactions of each have taken place? | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select transaction_type , count ( * ) from financial_transactions group by transaction_type
### Instruction:

Convert text to sql: What is the transaction type that has processed the greatest total amount in transactions? | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ from _ group by _ order by sum ( _ ) desc limit _ | select transaction_type from financial_transactions group by transaction_type order by sum ( transaction_amount ) desc limit 1
### Instruction:

Convert text to sql: Return the type of transaction with the highest total amount. | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ from _ group by _ order by sum ( _ ) desc limit _ | select transaction_type from financial_transactions group by transaction_type order by sum ( transaction_amount ) desc limit 1
### Instruction:

Convert text to sql: Show the account id and the number of transactions for each account | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select account_id , count ( * ) from financial_transactions group by account_id
### Instruction:

Convert text to sql: What are the different account ids that have made financial transactions, as well as how many transactions correspond to each? | accounts : account_id , customer_id , account_name , other_account_details | customers : customer_id , customer_first_name , customer_last_name , customer_address , customer_phone , customer_email , other_customer_details | customers_cards : card_id , customer_id , card_type_code , card_number , date_valid_from , date_valid_to , other_card_details | financial_transactions : transaction_id , previous_transaction_id , account_id , card_id , transaction_type , transaction_date , transaction_amount , transaction_comment , other_transaction_details | financial_transactions.account_id = accounts.account_id | financial_transactions.card_id = customers_cards.card_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select account_id , count ( * ) from financial_transactions group by account_id
### Instruction:

Convert text to sql: How many tracks do we have? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select count ( _ ) from _ | select count ( * ) from track
### Instruction:

Convert text to sql: Count the number of tracks. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select count ( _ ) from _ | select count ( * ) from track
### Instruction:

Convert text to sql: Show the name and location for all tracks. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ | select name , location from track
### Instruction:

Convert text to sql: What are the names and locations of all tracks? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ | select name , location from track
### Instruction:

Convert text to sql: Show names and seatings, ordered by seating for all tracks opened after 2000. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ order by _ asc | select name , seating from track where year_opened > 2000 order by seating asc
### Instruction:

Convert text to sql: What are the names and seatings for all tracks opened after 2000, ordered by seating? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ order by _ asc | select name , seating from track where year_opened > 2000 order by seating asc
### Instruction:

Convert text to sql: What is the name, location and seating for the most recently opened track? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ order by _ desc limit _ | select name , location , seating from track order by year_opened desc limit 1
### Instruction:

Convert text to sql: Return the name, location, and seating of the track that was opened in the most recent year. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ order by _ desc limit _ | select name , location , seating from track order by year_opened desc limit 1
### Instruction:

Convert text to sql: What is the minimum, maximum, and average seating for all tracks. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select min ( _ ) , max ( _ ) , avg ( _ ) from _ | select min ( seating ) , max ( seating ) , avg ( seating ) from track
### Instruction:

Convert text to sql: Return the minimum, maximum, and average seating across all tracks. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select min ( _ ) , max ( _ ) , avg ( _ ) from _ | select min ( seating ) , max ( seating ) , avg ( seating ) from track
### Instruction:

Convert text to sql: Show the name, location, open year for all tracks with a seating higher than the average. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ > ( select avg ( _ ) from _ ) | select name , location , year_opened from track where seating > ( select avg ( seating ) from track )
### Instruction:

Convert text to sql: What are the names, locations, and years of opening for tracks with seating higher than average? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ > ( select avg ( _ ) from _ ) | select name , location , year_opened from track where seating > ( select avg ( seating ) from track )
### Instruction:

Convert text to sql: What are distinct locations where tracks are located? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select distinct _ from _ | select distinct location from track
### Instruction:

Convert text to sql: Give the different locations of tracks. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select distinct _ from _ | select distinct location from track
### Instruction:

Convert text to sql: How many races are there? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select count ( _ ) from _ | select count ( * ) from race
### Instruction:

Convert text to sql: Count the number of races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select count ( _ ) from _ | select count ( * ) from race
### Instruction:

Convert text to sql: What are the distinct classes that races can have? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select distinct _ from _ | select distinct class from race
### Instruction:

Convert text to sql: Return the different classes of races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select distinct _ from _ | select distinct class from race
### Instruction:

Convert text to sql: Show name, class, and date for all races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ | select name , class , date from race
### Instruction:

Convert text to sql: What are the names, classes, and dates for all races? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ | select name , class , date from race
### Instruction:

Convert text to sql: Show the race class and number of races in each class. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select class , count ( * ) from race group by class
### Instruction:

Convert text to sql: What are the different classes of races, and how many races correspond to each? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select class , count ( * ) from race group by class
### Instruction:

Convert text to sql: What is the race class with most number of races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ group by _ order by count ( _ ) desc limit _ | select class from race group by class order by count ( * ) desc limit 1
### Instruction:

Convert text to sql: Give the class of races that is most common. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ group by _ order by count ( _ ) desc limit _ | select class from race group by class order by count ( * ) desc limit 1
### Instruction:

Convert text to sql: List the race class with at least two races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ group by _ having count ( _ ) >= _ | select class from race group by class having count ( * ) >= 2
### Instruction:

Convert text to sql: What are the classes of races that have two or more corresponding races? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ group by _ having count ( _ ) >= _ | select class from race group by class having count ( * ) >= 2
### Instruction:

Convert text to sql: What are the names for tracks without a race in class 'GT'. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ except select _ from _ where _ | select name from track except select track.name from race join track on race.track_id = track.track_id where race.class = 'GT'
### Instruction:

Convert text to sql: Give the names of tracks that do not have a race in the class 'GT'. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ except select _ from _ where _ | select name from track except select track.name from race join track on race.track_id = track.track_id where race.class = 'GT'
### Instruction:

Convert text to sql: Show all track names that have had no races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ not in ( select _ from _ ) | select name from track where track_id not in ( select track_id from race )
### Instruction:

Convert text to sql: Return the names of tracks that have no had any races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ not in ( select _ from _ ) | select name from track where track_id not in ( select track_id from race )
### Instruction:

Convert text to sql: Show year where a track with a seating at least 5000 opened and a track with seating no more than 4000 opened. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ between _ and _ | select year_opened from track where seating between 4000 and 5000
### Instruction:

Convert text to sql: What are the years of opening for tracks with seating between 4000 and 5000? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ where _ between _ and _ | select year_opened from track where seating between 4000 and 5000
### Instruction:

Convert text to sql: Show the name of track and the number of races in each track. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select track.name , count ( * ) from race join track on race.track_id = track.track_id group by race.track_id
### Instruction:

Convert text to sql: What are the names of different tracks, and how many races has each had? | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ , count ( _ ) from _ group by _ | select track.name , count ( * ) from race join track on race.track_id = track.track_id group by race.track_id
### Instruction:

Convert text to sql: Show the name of track with most number of races. | race : race_id , name , class , date , track_id | track : track_id , name , location , seating , year_opened | race.track_id = track.track_id | 

### Response:

select _ from _ group by _ order by count ( _ ) desc limit _ | select track.name from race join track on race.track_id = track.track_id group by race.track_id order by count ( * ) desc limit 1