db_id
stringlengths
4
31
SQL
stringlengths
18
1.45k
input_sequence
stringlengths
148
11k
question
stringlengths
16
325
manufactory_1
select name from manufacturers where revenue > (select avg(revenue) from manufacturers)
Question: find the name of companies whose revenue is greater than the average revenue of all companies. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the name of companies whose revenue is greater than the average revenue of all companies.
manufactory_1
select name from manufacturers where revenue > (select avg(revenue) from manufacturers)
Question: what are the names of manufacturers with revenue greater than the average of all revenues? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names of manufacturers with revenue greater than the average of all revenues?
manufactory_1
select name from manufacturers where revenue < (select min(revenue) from manufacturers where headquarter = 'austin')
Question: find the name of companies whose revenue is smaller than the revenue of all companies based in austin. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the name of companies whose revenue is smaller than the revenue of all companies based in austin.
manufactory_1
select name from manufacturers where revenue < (select min(revenue) from manufacturers where headquarter = 'austin')
Question: what are the names of companies with revenue less than the lowest revenue of any manufacturer in austin? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names of companies with revenue less than the lowest revenue of any manufacturer in austin?
manufactory_1
select sum(revenue) from manufacturers where revenue > (select min(revenue) from manufacturers where headquarter = 'austin')
Question: find the total revenue of companies whose revenue is larger than the revenue of some companies based in austin. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the total revenue of companies whose revenue is larger than the revenue of some companies based in austin.
manufactory_1
select sum(revenue) from manufacturers where revenue > (select min(revenue) from manufacturers where headquarter = 'austin')
Question: what is the total revenue of companies with revenue greater than the lowest revenue of any manufacturer in austin? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is the total revenue of companies with revenue greater than the lowest revenue of any manufacturer in austin?
manufactory_1
select sum(revenue) , founder from manufacturers group by founder
Question: find the total revenue of companies of each founder. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the total revenue of companies of each founder.
manufactory_1
select sum(revenue) , founder from manufacturers group by founder
Question: what is the total revenue of companies started by founder? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is the total revenue of companies started by founder?
manufactory_1
select name , max(revenue) , headquarter from manufacturers group by headquarter
Question: find the name and revenue of the company that earns the highest revenue in each city. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the name and revenue of the company that earns the highest revenue in each city.
manufactory_1
select name , max(revenue) , headquarter from manufacturers group by headquarter
Question: what are the names and revenues of the companies with the highest revenues in each headquarter city? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names and revenues of the companies with the highest revenues in each headquarter city?
manufactory_1
select sum(revenue) , name from manufacturers group by name
Question: find the total revenue for each manufacturer. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the total revenue for each manufacturer.
manufactory_1
select sum(revenue) , name from manufacturers group by name
Question: what is the total revenue of each manufacturer? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is the total revenue of each manufacturer?
manufactory_1
select avg(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: find the average prices of all products from each manufacture, and list each company's name. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the average prices of all products from each manufacture, and list each company's name.
manufactory_1
select avg(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: what are the average prices of products for each manufacturer? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the average prices of products for each manufacturer?
manufactory_1
select count(distinct t1.name) , t2.headquarter from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.headquarter
Question: find the number of different products that are produced by companies at different headquarter cities. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the number of different products that are produced by companies at different headquarter cities.
manufactory_1
select count(distinct t1.name) , t2.headquarter from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.headquarter
Question: how many different products are produced in each headquarter city? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
how many different products are produced in each headquarter city?
manufactory_1
select count(distinct name) from products where name not in (select t1.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code where t2.name = 'sony')
Question: find number of products which sony does not make. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find number of products which sony does not make.
manufactory_1
select count(distinct name) from products where name not in (select t1.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code where t2.name = 'sony')
Question: how many products are not made by sony? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
how many products are not made by sony?
manufactory_1
select name from manufacturers except select t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code where t1.name = 'dvd drive'
Question: find the name of companies that do not make dvd drive. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the name of companies that do not make dvd drive.
manufactory_1
select name from manufacturers except select t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code where t1.name = 'dvd drive'
Question: what are the names of companies that do not make dvd drives? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names of companies that do not make dvd drives?
manufactory_1
select count(*) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: find the number of products for each manufacturer, showing the name of each company. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find the number of products for each manufacturer, showing the name of each company.
manufactory_1
select count(*) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: how many products are there for each manufacturer? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
how many products are there for each manufacturer?
manufactory_1
select name from products
Question: select the names of all the products in the store. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the names of all the products in the store.
manufactory_1
select name from products
Question: what are the names of all products? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names of all products?
manufactory_1
select name , price from products
Question: select the names and the prices of all the products in the store. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the names and the prices of all the products in the store.
manufactory_1
select name , price from products
Question: what are the names and prices of all products in the store? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names and prices of all products in the store?
manufactory_1
select name from products where price <= 200
Question: select the name of the products with a price less than or equal to $200. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the name of the products with a price less than or equal to $200.
manufactory_1
select name from products where price <= 200
Question: what are the names of products with price at most 200? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names of products with price at most 200?
manufactory_1
select * from products where price between 60 and 120
Question: find all information of all the products with a price between $60 and $120. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
find all information of all the products with a price between $60 and $120.
manufactory_1
select * from products where price between 60 and 120
Question: what is all the information of all the products that have a price between 60 and 120? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is all the information of all the products that have a price between 60 and 120?
manufactory_1
select avg(price) from products
Question: compute the average price of all the products. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
compute the average price of all the products.
manufactory_1
select avg(price) from products
Question: what is the average price across all products? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is the average price across all products?
manufactory_1
select avg(price) from products where manufacturer = 2
Question: compute the average price of all products with manufacturer code equal to 2. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
compute the average price of all products with manufacturer code equal to 2.
manufactory_1
select avg(price) from products where manufacturer = 2
Question: what is the average price of products with manufacturer codes equal to 2? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is the average price of products with manufacturer codes equal to 2?
manufactory_1
select count(*) from products where price >= 180
Question: compute the number of products with a price larger than or equal to $180. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
compute the number of products with a price larger than or equal to $180.
manufactory_1
select count(*) from products where price >= 180
Question: how many products have prices of at least 180? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
how many products have prices of at least 180?
manufactory_1
select name , price from products where price >= 180 order by price desc , name asc
Question: select the name and price of all products with a price larger than or equal to $180, and sort first by price (in descending order), and then by name (in ascending order). | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manuf...
select the name and price of all products with a price larger than or equal to $180, and sort first by price (in descending order), and then by name (in ascending order).
manufactory_1
select name , price from products where price >= 180 order by price desc , name asc
Question: what are the names and prices of products that cost at least 180, sorted by price decreasing and name ascending? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names and prices of products that cost at least 180, sorted by price decreasing and name ascending?
manufactory_1
select * from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code
Question: select all the data from the products and each product's manufacturer. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select all the data from the products and each product's manufacturer.
manufactory_1
select * from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code
Question: what is all the product data, as well as each product's manufacturer? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is all the product data, as well as each product's manufacturer?
manufactory_1
select avg(price) , manufacturer from products group by manufacturer
Question: select the average price of each manufacturer's products, showing only the manufacturer's code. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the average price of each manufacturer's products, showing only the manufacturer's code.
manufactory_1
select avg(price) , manufacturer from products group by manufacturer
Question: what are the average prices of products, grouped by manufacturer code? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the average prices of products, grouped by manufacturer code?
manufactory_1
select avg(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: select the average price of each manufacturer's products, showing the manufacturer's name. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the average price of each manufacturer's products, showing the manufacturer's name.
manufactory_1
select avg(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: what are the average prices of products, grouped by manufacturer name? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the average prices of products, grouped by manufacturer name?
manufactory_1
select avg(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name having avg(t1.price) >= 150
Question: select the names of manufacturer whose products have an average price higher than or equal to $150. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the names of manufacturer whose products have an average price higher than or equal to $150.
manufactory_1
select avg(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name having avg(t1.price) >= 150
Question: what are the names and average prices of products for manufacturers whose products cost on average 150 or more? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the names and average prices of products for manufacturers whose products cost on average 150 or more?
manufactory_1
select name , price from products order by price asc limit 1
Question: select the name and price of the cheapest product. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the name and price of the cheapest product.
manufactory_1
select name , price from products order by price asc limit 1
Question: what is the name and price of the cheapest product? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what is the name and price of the cheapest product?
manufactory_1
select t1.name , max(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: select the name of each manufacturer along with the name and price of its most expensive product. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the name of each manufacturer along with the name and price of its most expensive product.
manufactory_1
select t1.name , max(t1.price) , t2.name from products as t1 join manufacturers as t2 on t1.manufacturer = t2.code group by t2.name
Question: for each manufacturer name, what are the names and prices of their most expensive product? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
for each manufacturer name, what are the names and prices of their most expensive product?
manufactory_1
select code , name , min(price) from products group by name
Question: select the code of the product that is cheapest in each product category. | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
select the code of the product that is cheapest in each product category.
manufactory_1
select code , name , min(price) from products group by name
Question: what are the codes and names of the cheapest products in each category? | Tables: Manufacturers -> Code, Name, Headquarter, Founder, Revenue. Products -> Code, Name, Price, Manufacturer. | Joins: Products.Manufacturer = Manufacturers.Code,
what are the codes and names of the cheapest products in each category?
tracking_software_problems
select problem_log_id from problem_log order by log_entry_date desc limit 1
Question: what is the id of the problem log that is created most recently? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entr...
what is the id of the problem log that is created most recently?
tracking_software_problems
select problem_log_id from problem_log order by log_entry_date desc limit 1
Question: which problem log was created most recently? give me the log id. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entr...
which problem log was created most recently? give me the log id.
tracking_software_problems
select problem_log_id , problem_id from problem_log order by log_entry_date limit 1
Question: what is the oldest log id and its corresponding problem id? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix...
what is the oldest log id and its corresponding problem id?
tracking_software_problems
select problem_log_id , problem_id from problem_log order by log_entry_date limit 1
Question: find the oldest log id and its corresponding problem id. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix, o...
find the oldest log id and its corresponding problem id.
tracking_software_problems
select problem_log_id , log_entry_date from problem_log where problem_id = 10
Question: find all the ids and dates of the logs for the problem whose id is 10. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, lo...
find all the ids and dates of the logs for the problem whose id is 10.
tracking_software_problems
select problem_log_id , log_entry_date from problem_log where problem_id = 10
Question: for the problem with id 10, return the ids and dates of its problem logs. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description,...
for the problem with id 10, return the ids and dates of its problem logs.
tracking_software_problems
select problem_log_id , log_entry_description from problem_log
Question: list all the log ids and their descriptions from the problem logs. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_en...
list all the log ids and their descriptions from the problem logs.
tracking_software_problems
select problem_log_id , log_entry_description from problem_log
Question: what are the log id and entry description of each problem? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix,...
what are the log id and entry description of each problem?
tracking_software_problems
select distinct staff_first_name , staff_last_name from staff as t1 join problem_log as t2 on t1.staff_id = t2.assigned_to_staff_id where t2.problem_id = 1
Question: list the first and last names of all distinct staff members who are assigned to the problem whose id is 1. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_e...
list the first and last names of all distinct staff members who are assigned to the problem whose id is 1.
tracking_software_problems
select distinct staff_first_name , staff_last_name from staff as t1 join problem_log as t2 on t1.staff_id = t2.assigned_to_staff_id where t2.problem_id = 1
Question: which staff members are assigned to the problem with id 1? give me their first and last names. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, l...
which staff members are assigned to the problem with id 1? give me their first and last names.
tracking_software_problems
select distinct t2.problem_id , t2.problem_log_id from staff as t1 join problem_log as t2 on t1.staff_id = t2.assigned_to_staff_id where t1.staff_first_name = 'rylan' and t1.staff_last_name = 'homenick'
Question: list the problem id and log id which are assigned to the staff named rylan homenick. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_d...
list the problem id and log id which are assigned to the staff named rylan homenick.
tracking_software_problems
select distinct t2.problem_id , t2.problem_log_id from staff as t1 join problem_log as t2 on t1.staff_id = t2.assigned_to_staff_id where t1.staff_first_name = 'rylan' and t1.staff_last_name = 'homenick'
Question: which problem id and log id are assigned to the staff named rylan homenick? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_descriptio...
which problem id and log id are assigned to the staff named rylan homenick?
tracking_software_problems
select count(*) from product as t1 join problems as t2 on t1.product_id = t2.product_id where t1.product_name = 'voluptatem'
Question: how many problems are there for product voluptatem? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix, other_...
how many problems are there for product voluptatem?
tracking_software_problems
select count(*) from product as t1 join problems as t2 on t1.product_id = t2.product_id where t1.product_name = 'voluptatem'
Question: how many problems did the product called 'voluptatem' have in record? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log...
how many problems did the product called 'voluptatem' have in record?
tracking_software_problems
select count(*) , t1.product_name from product as t1 join problems as t2 on t1.product_id = t2.product_id group by t1.product_name order by count(*) desc limit 1
Question: how many problems does the product with the most problems have? list the number of the problems and product name. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code...
how many problems does the product with the most problems have? list the number of the problems and product name.
tracking_software_problems
select count(*) , t1.product_name from product as t1 join problems as t2 on t1.product_id = t2.product_id group by t1.product_name order by count(*) desc limit 1
Question: which product has the most problems? give me the number of problems and the product name. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_en...
which product has the most problems? give me the number of problems and the product name.
tracking_software_problems
select t1.problem_description from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'christop'
Question: give me a list of descriptions of the problems that are reported by the staff whose first name is christop. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_...
give me a list of descriptions of the problems that are reported by the staff whose first name is christop.
tracking_software_problems
select t1.problem_description from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'christop'
Question: which problems are reported by the staff with first name 'christop'? show the descriptions of the problems. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_...
which problems are reported by the staff with first name 'christop'? show the descriptions of the problems.
tracking_software_problems
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'
Question: find the ids of the problems that are reported by the staff whose last name is bosco. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_...
find the ids of the problems that are reported by the staff whose last name is bosco.
tracking_software_problems
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'
Question: which problems are reported by the staff with last name 'bosco'? show the ids of the problems. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, l...
which problems are reported by the staff with last name 'bosco'? show the ids of the problems.
tracking_software_problems
select problem_id from problems where date_problem_reported > '1978-06-26'
Question: what are the ids of the problems which are reported after 1978-06-26? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log...
what are the ids of the problems which are reported after 1978-06-26?
tracking_software_problems
select problem_id from problems where date_problem_reported > '1978-06-26'
Question: find the ids of the problems reported after 1978-06-26. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix, ot...
find the ids of the problems reported after 1978-06-26.
tracking_software_problems
select problem_id from problems where date_problem_reported < '1978-06-26'
Question: what are the ids of the problems which are reported before 1978-06-26? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, lo...
what are the ids of the problems which are reported before 1978-06-26?
tracking_software_problems
select problem_id from problems where date_problem_reported < '1978-06-26'
Question: which problems are reported before 1978-06-26? give me the ids of the problems. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_descri...
which problems are reported before 1978-06-26? give me the ids of the problems.
tracking_software_problems
select count(*) , t2.product_id from problems as t1 join product as t2 on t1.product_id = t2.product_id group by t2.product_id
Question: for each product which has problems, what are the number of problems and the product id? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_ent...
for each product which has problems, what are the number of problems and the product id?
tracking_software_problems
select count(*) , t2.product_id from problems as t1 join product as t2 on t1.product_id = t2.product_id group by t2.product_id
Question: for each product with some problems, list the count of problems and the product id. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_de...
for each product with some problems, list the count of problems and the product id.
tracking_software_problems
select count(*) , t2.product_id from problems as t1 join product as t2 on t1.product_id = t2.product_id where t1.date_problem_reported > '1986-11-13' group by t2.product_id
Question: for each product that has problems, find the number of problems reported after 1986-11-13 and the product id? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, lo...
for each product that has problems, find the number of problems reported after 1986-11-13 and the product id?
tracking_software_problems
select count(*) , t2.product_id from problems as t1 join product as t2 on t1.product_id = t2.product_id where t1.date_problem_reported > '1986-11-13' group by t2.product_id
Question: what are the products that have problems reported after 1986-11-13? give me the product id and the count of problems reported after 1986-11-13. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_cate...
what are the products that have problems reported after 1986-11-13? give me the product id and the count of problems reported after 1986-11-13.
tracking_software_problems
select distinct product_name from product order by product_name
Question: list the names of all the distinct product names in alphabetical order? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, l...
list the names of all the distinct product names in alphabetical order?
tracking_software_problems
select distinct product_name from product order by product_name
Question: sort all the distinct product names in alphabetical order. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix,...
sort all the distinct product names in alphabetical order.
tracking_software_problems
select distinct product_name from product order by product_id
Question: list all the distinct product names ordered by product id? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix,...
list all the distinct product names ordered by product id?
tracking_software_problems
select distinct product_name from product order by product_id
Question: what is the list of distinct product names sorted by product id? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entr...
what is the list of distinct product names sorted by product id?
tracking_software_problems
select product_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'dameon' and t2.staff_last_name = 'frami' union select product_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'jolie' and t2.staff_las...
Question: what are the id of problems reported by the staff named dameon frami or jolie weber? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_d...
what are the id of problems reported by the staff named dameon frami or jolie weber?
tracking_software_problems
select product_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'dameon' and t2.staff_last_name = 'frami' union select product_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'jolie' and t2.staff_las...
Question: which problems were reported by the staff named dameon frami or jolie weber? give me the ids of the problems. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, lo...
which problems were reported by the staff named dameon frami or jolie weber? give me the ids of the problems.
tracking_software_problems
select product_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'christop' and t2.staff_last_name = 'berge' intersect select product_id from problems as t1 join staff as t2 on t1.closure_authorised_by_staff_id = t2.staff_id where t2.staff_first_name = 'ashley'...
Question: what are the product ids for the problems reported by christop berge with closure authorised by ashley medhurst? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code,...
what are the product ids for the problems reported by christop berge with closure authorised by ashley medhurst?
tracking_software_problems
select product_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where t2.staff_first_name = 'christop' and t2.staff_last_name = 'berge' intersect select product_id from problems as t1 join staff as t2 on t1.closure_authorised_by_staff_id = t2.staff_id where t2.staff_first_name = 'ashley'...
Question: for which product was there a problem reported by christop berge, with closure authorised by ashley medhurst? return the product ids. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code,...
for which product was there a problem reported by christop berge, with closure authorised by ashley medhurst? return the product ids.
tracking_software_problems
select t1.problem_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where date_problem_reported < ( select min(date_problem_reported) from problems as t3 join staff as t4 on t3.reported_by_staff_id = t4.staff_id where t4.staff_first_name = 'lysanne' and t4.staff_last_name = 'turcotte' )
Question: what are the ids of the problems reported before the date of any problem reported by lysanne turcotte? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry...
what are the ids of the problems reported before the date of any problem reported by lysanne turcotte?
tracking_software_problems
select t1.problem_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where date_problem_reported < ( select min(date_problem_reported) from problems as t3 join staff as t4 on t3.reported_by_staff_id = t4.staff_id where t4.staff_first_name = 'lysanne' and t4.staff_last_name = 'turcotte' )
Question: which problems were reported before the date of any problem reported by the staff lysanne turcotte? give me the ids of the problems. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, ...
which problems were reported before the date of any problem reported by the staff lysanne turcotte? give me the ids of the problems.
tracking_software_problems
select t1.problem_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where date_problem_reported > ( select max(date_problem_reported) from problems as t3 join staff as t4 on t3.reported_by_staff_id = t4.staff_id where t4.staff_first_name = 'rylan' and t4.staff_last_name = 'homenick' )
Question: what are the ids of the problems reported after the date of any problems reported by rylan homenick? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_d...
what are the ids of the problems reported after the date of any problems reported by rylan homenick?
tracking_software_problems
select t1.problem_id from problems as t1 join staff as t2 on t1.reported_by_staff_id = t2.staff_id where date_problem_reported > ( select max(date_problem_reported) from problems as t3 join staff as t4 on t3.reported_by_staff_id = t4.staff_id where t4.staff_first_name = 'rylan' and t4.staff_last_name = 'homenick' )
Question: find the ids of the problems reported after the date of any problems reported by the staff rylan homenick. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_e...
find the ids of the problems reported after the date of any problems reported by the staff rylan homenick.
tracking_software_problems
select t2.product_name from problems as t1 join product as t2 on t1.product_id = t2.product_id group by t2.product_name order by count(*) desc limit 3
Question: find the top 3 products which have the largest number of problems? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_en...
find the top 3 products which have the largest number of problems?
tracking_software_problems
select t2.product_name from problems as t1 join product as t2 on t1.product_id = t2.product_id group by t2.product_name order by count(*) desc limit 3
Question: what are the three products that have the most problems?s | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entry_description, log_entry_fix, ...
what are the three products that have the most problems?s
tracking_software_problems
select t1.problem_id from problems as t1 join product as t2 on t1.product_id = t2.product_id where t2.product_name = 'voluptatem' and t1.date_problem_reported > '1995'
Question: list the ids of the problems from the product 'voluptatem' that are reported after 1995? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_ent...
list the ids of the problems from the product 'voluptatem' that are reported after 1995?
tracking_software_problems
select t1.problem_id from problems as t1 join product as t2 on t1.product_id = t2.product_id where t2.product_name = 'voluptatem' and t1.date_problem_reported > '1995'
Question: what are the ids of the problems that are from the product 'voluptatem' and are reported after 1995? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_d...
what are the ids of the problems that are from the product 'voluptatem' and are reported after 1995?
tracking_software_problems
select t3.staff_first_name , t3.staff_last_name from problems as t1 join product as t2 join staff as t3 on t1.product_id = t2.product_id and t1.reported_by_staff_id = t3.staff_id where t2.product_name = 'rem' except select t3.staff_first_name , t3.staff_last_name from problems as t1 join product as t2 join staff as t...
Question: find the first and last name of the staff members who reported problems from the product 'rem' but not 'aut'? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, lo...
find the first and last name of the staff members who reported problems from the product 'rem' but not 'aut'?
tracking_software_problems
select t3.staff_first_name , t3.staff_last_name from problems as t1 join product as t2 join staff as t3 on t1.product_id = t2.product_id and t1.reported_by_staff_id = t3.staff_id where t2.product_name = 'rem' except select t3.staff_first_name , t3.staff_last_name from problems as t1 join product as t2 join staff as t...
Question: which staff members who reported problems from the product 'rem' but not 'aut'? give me their first and last names. | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_co...
which staff members who reported problems from the product 'rem' but not 'aut'? give me their first and last names.
tracking_software_problems
select t2.product_name from problems as t1 join product as t2 join staff as t3 on t1.product_id = t2.product_id and t1.reported_by_staff_id = t3.staff_id where t3.staff_first_name = 'lacey' and t3.staff_last_name = 'bosco' intersect select t2.product_name from problems as t1 join product as t2 join staff as t3 on t1.pr...
Question: find the products which have problems reported by both lacey bosco and kenton champlin? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, log_entry_date, log_entr...
find the products which have problems reported by both lacey bosco and kenton champlin?
tracking_software_problems
select t2.product_name from problems as t1 join product as t2 join staff as t3 on t1.product_id = t2.product_id and t1.reported_by_staff_id = t3.staff_id where t3.staff_first_name = 'lacey' and t3.staff_last_name = 'bosco' intersect select t2.product_name from problems as t1 join product as t2 join staff as t3 on t1.pr...
Question: which products have problems reported by both the staff named lacey bosco and the staff named kenton champlin? | Tables: Problem_Category_Codes -> problem_category_code, problem_category_description. Problem_Log -> problem_log_id, assigned_to_staff_id, problem_id, problem_category_code, problem_status_code, l...
which products have problems reported by both the staff named lacey bosco and the staff named kenton champlin?