Question: Find the name, headquarter and revenue of all manufacturers sorted by their revenue in the descending order.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , headquarter (text) , revenue (number)


Question: What are the names, headquarters and revenues for manufacturers, sorted by revenue descending?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , headquarter (text) , revenue (number)


Question: Find the name of companies whose revenue is greater than the average revenue of all companies.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , revenue (number)


Question: What are the names of manufacturers with revenue greater than the average of all revenues?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , revenue (number)


Question: Find the name of companies whose revenue is smaller than the revenue of all companies based in Austin.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , revenue (number) , headquarter (text)


Question: What are the names of companies with revenue less than the lowest revenue of any manufacturer in Austin?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , revenue (number) , headquarter (text)


Question: Find the total revenue of companies whose revenue is larger than the revenue of some companies based in Austin.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : revenue (number) , headquarter (text)


Question: What is the total revenue of companies with revenue greater than the lowest revenue of any manufacturer in Austin?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : revenue (number) , headquarter (text)


Question: Find the total revenue of companies of each founder.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : revenue (number) , founder (text)


Question: What is the total revenue of companies started by founder?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : revenue (number) , founder (text)


Question: Find the name and revenue of the company that earns the highest revenue in each city.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , revenue (number) , headquarter (text)


Question: What are the names and revenues of the companies with the highest revenues in each headquarter city?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , revenue (number) , headquarter (text)


Question: Find the total revenue for each manufacturer.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : revenue (number) , name (text)


Question: What is the total revenue of each manufacturer?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : revenue (number) , name (text)


Question: Find the average prices of all products from each manufacture, and list each company's name.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , name (text) , manufacturer (number) , code (number) | manufacturers : name (text) , code (number)


Question: What are the average prices of products for each manufacturer?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , name (text) , manufacturer (number) , code (number) | manufacturers : name (text) , code (number)


Question: Find the number of different products that are produced by companies at different headquarter cities.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , headquarter (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: How many different products are produced in each headquarter city?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , headquarter (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: Find number of products which Sony does not make.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: How many products are not made by Sony?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: Find the name of companies that do not make DVD drive.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: What are the names of companies that do not make DVD drives?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: Find the number of products for each manufacturer, showing the name of each company.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: How many products are there for each manufacturer?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , manufacturer (number) , code (number)


Question: Select the names of all the products in the store.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What are the names of all products?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: Select the names and the prices of all the products in the store.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What are the names and prices of all products in the store?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: Select the name of the products with a price less than or equal to $200.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What are the names of products with price at most 200?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: Find all information of all the products with a price between $60 and $120.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , code (number)


Question: What is all the information of all the products that have a price between 60 and 120?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , code (number)


Question: Compute the average price of all the products.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What is the average price across all products?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: Compute the average price of all products with manufacturer code equal to 2.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , manufacturer (number)


Question: What is the average price of products with manufacturer codes equal to 2?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , manufacturer (number)


Question: Compute the number of products with a price larger than or equal to $180.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , code (number)


Question: How many products have prices of at least 180?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , code (number)


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).

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What are the names and prices of products that cost at least 180, sorted by price decreasing and name ascending?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: Select all the data from the products and each product's manufacturer.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : manufacturer (number) , code (number) | manufacturers : code (number)


Question: What is all the product data, as well as  each product's manufacturer?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : manufacturer (number) , code (number) | manufacturers : code (number)


Question: Select the average price of each manufacturer's products, showing only the manufacturer's code.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , manufacturer (number)


Question: What are the average prices of products, grouped by manufacturer code?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , manufacturer (number)


Question: Select the average price of each manufacturer's products, showing the manufacturer's name.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , name (text) , manufacturer (number) , code (number) | manufacturers : name (text) , code (number)


Question: What are the average prices of products, grouped by manufacturer name?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , name (text) , manufacturer (number) , code (number) | manufacturers : name (text) , code (number)


Question: Select the names of manufacturer whose products have an average price higher than or equal to $150.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , name (text) , manufacturer (number) , code (number) | manufacturers : name (text) , code (number)


Question: What are the names and average prices of products for manufacturers whose products cost on average 150 or more?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

products : price (number) , name (text) , manufacturer (number) , code (number) | manufacturers : name (text) , code (number)


Question: Select the name and price of the cheapest product.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What is the name and price of the cheapest product?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: Select the name of each manufacturer along with the name and price of its most expensive product.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , price (number) , manufacturer (number) , code (number)


Question: For each manufacturer name, what are the names and prices of their most expensive product?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)

manufacturers : name (text) , code (number) | products : name (text) , price (number) , manufacturer (number) , code (number)


Question: Select the code of the product that is cheapest in each product category.

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What are the codes and names of the cheapest products in each category?

manufacturers : code (number) , name (text) , headquarter (text) , founder (text) , revenue (number) | products : code (number) , name (text) , price (number) , manufacturer (number)


Question: What is the id of the problem log that is created most recently?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , log_entry_date (time)


Question: Which problem log was created most recently? Give me the log id.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , log_entry_date (time)


Question: What is the oldest log id and its corresponding problem id?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , problem_id (number) , log_entry_date (time)


Question: Find the oldest log id and its corresponding problem id.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , problem_id (number) , log_entry_date (time)


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

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , log_entry_date (time) , problem_id (number)


Question: For the problem with id 10, return the ids and dates of its problem logs.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , log_entry_date (time) , problem_id (number)


Question: List all the log ids and their descriptions from the problem logs.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , log_entry_description (text)


Question: What are the log id and entry description of each problem?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_log_id (number) , log_entry_description (text)


Question: List the first and last names of all distinct staff members who are assigned to the problem whose id is 1.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

staff : staff_first_name (text) , staff_last_name (text) , staff_id (number) | problem_log : assigned_to_staff_id (number) , problem_id (number)


Question: Which staff members are assigned to the problem with id 1? Give me their first and last names.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

staff : staff_first_name (text) , staff_last_name (text) , staff_id (number) | problem_log : assigned_to_staff_id (number) , problem_id (number)


Question: List the problem id and log id which are assigned to the staff named Rylan Homenick.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_id (number) , problem_log_id (number) , assigned_to_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: Which problem id and log id are assigned to the staff named Rylan Homenick?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problem_log : problem_id (number) , problem_log_id (number) , assigned_to_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: How many problems are there for product voluptatem?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_id (number) , product_name (text) | problems : product_id (number) , problem_id (number)


Question: How many problems did the product called "voluptatem" have in record?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_id (number) , product_name (text) | problems : product_id (number) , problem_id (number)


Question: How many problems does the product with the most problems have? List the number of the problems and product name.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number) | problems : product_id (number) , problem_id (number)


Question: Which product has the most problems? Give me the number of problems and the product name.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number) | problems : product_id (number) , problem_id (number)


Question: Give me a list of descriptions of the problems that are reported by the staff whose first name is Christop.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_description (text) , reported_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text)


Question: Which problems are reported by the staff with first name "Christop"? Show the descriptions of the problems.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_description (text) , reported_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text)


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

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , reported_by_staff_id (number) | staff : staff_id (number) , staff_last_name (text)


Question: Which problems are reported by the staff with last name "Bosco"? Show the ids of the problems.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , reported_by_staff_id (number) | staff : staff_id (number) , staff_last_name (text)


Question: What are the ids of the problems which are reported after 1978-06-26?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , date_problem_reported (time)


Question: Find the ids of the problems reported after 1978-06-26.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , date_problem_reported (time)


Question: What are the ids of the problems which are reported before 1978-06-26?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , date_problem_reported (time)


Question: Which problems are reported before 1978-06-26? Give me the ids of the problems.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , date_problem_reported (time)


Question: For each product which has problems, what are the number of problems and the product id?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_id (number) | problems : product_id (number) , problem_id (number)


Question: For each product with some problems, list the count of problems and the product id.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_id (number) | problems : product_id (number) , problem_id (number)


Question: For each product that has problems, find the number of problems reported after 1986-11-13 and the product id?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_id (number) | problems : product_id (number) , date_problem_reported (time) , problem_id (number)


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.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_id (number) | problems : product_id (number) , date_problem_reported (time) , problem_id (number)


Question: List the names of all the distinct product names in alphabetical order?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)


Question: Sort all the distinct product names in alphabetical order.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)


Question: List all the distinct product names ordered by product id?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number)


Question: What is the list of distinct product names sorted by product id?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number)


Question: What are the id of problems reported by the staff named Dameon Frami or Jolie Weber?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : product_id (number) , reported_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: Which problems were reported by the staff named Dameon Frami or Jolie Weber? Give me the ids of the problems.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : product_id (number) , reported_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: What are the product ids for the problems reported by Christop Berge with closure authorised by Ashley Medhurst?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : product_id (number) , reported_by_staff_id (number) , closure_authorised_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: For which product was there a problem reported by Christop Berge, with closure authorised by Ashley Medhurst? Return the product ids.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : product_id (number) , reported_by_staff_id (number) , closure_authorised_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: What are the ids of the problems reported before the date of any problem reported by Lysanne Turcotte?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , reported_by_staff_id (number) , date_problem_reported (time) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: Which problems were reported before the date of any problem reported by the staff Lysanne Turcotte? Give me the ids of the problems.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , reported_by_staff_id (number) , date_problem_reported (time) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: What are the ids of the problems reported after the date of any problems reported by Rylan Homenick?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , reported_by_staff_id (number) , date_problem_reported (time) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: Find the ids of the problems reported after the date of any problems reported by the staff Rylan Homenick.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , reported_by_staff_id (number) , date_problem_reported (time) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: Find the top 3 products which have the largest number of problems?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number) | problems : product_id (number) , problem_id (number)


Question: What are the three products that have the most problems?s

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number) | problems : product_id (number) , problem_id (number)


Question: List the ids of the problems from the product "voluptatem" that are reported after 1995?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , product_id (number) , date_problem_reported (time) | product : product_id (number) , product_name (text)


Question: What are the ids of the problems that are from the product "voluptatem" and are reported after 1995?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

problems : problem_id (number) , product_id (number) , date_problem_reported (time) | product : product_id (number) , product_name (text)


Question: Find the first and last name of the staff members who reported problems from the product "rem" but not "aut"?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

staff : staff_first_name (text) , staff_last_name (text) , staff_id (number) | product : product_id (number) , product_name (text) | problems : product_id (number) , reported_by_staff_id (number)


Question: Which staff members who reported problems from the product "rem" but not "aut"? Give me their first and last names.

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

staff : staff_first_name (text) , staff_last_name (text) , staff_id (number) | product : product_id (number) , product_name (text) | problems : product_id (number) , reported_by_staff_id (number)


Question: Find the products which have problems reported by both Lacey Bosco and Kenton Champlin?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number) | problems : product_id (number) , reported_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: Which products have problems reported by both the staff named Lacey Bosco and the staff named Kenton Champlin?

problem_category_codes : problem_category_code (text) , problem_category_description (text) | problem_log : problem_log_id (number) , assigned_to_staff_id (number) , problem_id (number) , problem_category_code (text) , problem_status_code (text) , log_entry_date (time) , log_entry_description (text) , log_entry_fix (text) , other_log_details (text) | problem_status_codes : problem_status_code (text) , problem_status_description (text) | product : product_id (number) , product_name (text) , product_details (text) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text) , other_staff_details (text) | problems : problem_id (number) , product_id (number) , closure_authorised_by_staff_id (number) , reported_by_staff_id (number) , date_problem_reported (time) , date_problem_closed (time) , problem_description (text) , other_problem_details (text)

product : product_name (text) , product_id (number) | problems : product_id (number) , reported_by_staff_id (number) | staff : staff_id (number) , staff_first_name (text) , staff_last_name (text)


Question: How many branches where have more than average number of memberships are there?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : membership_amount (text) , branch_id (number)


Question: What is the number of branches that have more than the average number of memberships?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : membership_amount (text) , branch_id (number)


Question: Show name, address road, and city for all branches sorted by open year.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , address_road (text) , city (text) , open_year (text)


Question: What are the names, address roads, and cities of the branches ordered by opening year?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , address_road (text) , city (text) , open_year (text)


Question: What are names for top three branches with most number of membership?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , membership_amount (text)


Question: What are the names for the 3 branches that have the most memberships?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , membership_amount (text)


Question: Show all distinct city where branches with at least 100 memberships are located.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , membership_amount (text)


Question: What are the different cities that have more than 100 memberships?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , membership_amount (text)


Question: List all open years when at least two shops are opened.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : open_year (text) , branch_id (number)


Question: What are the opening years in which at least two shops opened?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : open_year (text) , branch_id (number)


Question: Show minimum and maximum amount of memberships for all branches opened in 2011 or located at city London.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : membership_amount (text) , open_year (text) , city (text)


Question: What are the minimum and maximum membership amounts for all branches that either opened in 2011 or are located in London?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : membership_amount (text) , open_year (text) , city (text)


Question: Show the city and the number of branches opened before 2010 for each city.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , open_year (text) , branch_id (number)


Question: For each city, how many branches opened before 2010?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , open_year (text) , branch_id (number)


Question: How many different levels do members have?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)


Question: What are the different membership levels?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)


Question: Show card number, name, and hometown for all members in a descending order of level.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : card_number (text) , name (text) , hometown (text) , level (number)


Question: What are the card numbers, names, and hometowns of every member ordered by descending level?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : card_number (text) , name (text) , hometown (text) , level (number)


Question: Show the membership level with most number of members.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : level (number) , member_id (number)


Question: What is the membership level with the most people?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : level (number) , member_id (number)


Question: Show all member names and registered branch names sorted by register year.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , member_id (number) | branch : name (text) , branch_id (number) | membership_register_branch : branch_id (text) , member_id (number) , register_year (text)


Question: What are the names of the members and branches at which they are registered sorted by year of registration?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , member_id (number) | branch : name (text) , branch_id (number) | membership_register_branch : branch_id (text) , member_id (number) , register_year (text)


Question: Show all branch names with the number of members in each branch registered after 2015.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , branch_id (number) | membership_register_branch : branch_id (text) , register_year (text) , member_id (number)


Question: For each branch id, what are the names of the branches that were registered after 2015?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , branch_id (number) | membership_register_branch : branch_id (text) , register_year (text) , member_id (number)


Question: Show member names without any registered branch.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , member_id (number) | membership_register_branch : member_id (number)


Question: What are the names of the members that have never registered at any branch?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , member_id (number) | membership_register_branch : member_id (number)


Question: List the branch name and city without any registered members.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , city (text) , branch_id (number) | membership_register_branch : branch_id (text)


Question: What are the names and cities of the branches that do not have any registered members?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , city (text) , branch_id (number) | membership_register_branch : branch_id (text)


Question: What is the name and open year for the branch with most number of memberships registered in 2016?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , open_year (text) , branch_id (number) | membership_register_branch : branch_id (text) , register_year (text) , member_id (number)


Question: What is the name and opening year for the branch that registered the most members in 2016?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : name (text) , open_year (text) , branch_id (number) | membership_register_branch : branch_id (text) , register_year (text) , member_id (number)


Question: Show the member name and hometown who registered a branch in 2016.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , hometown (text) , member_id (number) | membership_register_branch : member_id (number) , register_year (text)


Question: What are the member names and hometowns of those who registered at a branch in 2016?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , hometown (text) , member_id (number) | membership_register_branch : member_id (number) , register_year (text)


Question: Show all city with a branch opened in 2001 and a branch with more than 100 membership.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , open_year (text) , membership_amount (text)


Question: What are the cities that have a branch that opened in 2001 and a branch with more than 100 members?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , open_year (text) , membership_amount (text)


Question: Show all cities without a branch having more than 100 memberships.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , membership_amount (text)


Question: What are the cities that do not have any branches with more than 100 members?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

branch : city (text) , membership_amount (text)


Question: What is the sum of total pounds of purchase in year 2018 for all branches in London?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

purchase : total_pounds (number) , branch_id (text) , year (text) | branch : branch_id (number) , city (text)


Question: How many total pounds were purchased in the year 2018 at all London branches?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

purchase : total_pounds (number) , branch_id (text) , year (text) | branch : branch_id (number) , city (text)


Question: What is the total number of purchases for members with level 6?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : member_id (number) , level (number) | purchase : member_id (number)


Question: What are the total purchases for members rated at level 6?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : member_id (number) , level (number) | purchase : member_id (number)


Question: Find the name of branches where have some members whose hometown is in Louisville, Kentucky and some in Hiram, Georgia.

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , member_id (number) , hometown (text) | branch : name (text) , branch_id (number) | membership_register_branch : branch_id (text) , member_id (number)


Question: What are the names of the branches that have some members with a hometown in Louisville, Kentucky and also those from Hiram, Goergia?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : name (text) , member_id (number) , hometown (text) | branch : name (text) , branch_id (number) | membership_register_branch : branch_id (text) , member_id (number)


Question: list the card number of all members whose hometown address includes word "Kentucky".

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : card_number (text) , hometown (text)


Question: What are the card numbers of members from Kentucky?

member : member_id (number) , card_number (text) , name (text) , hometown (text) , level (number) | branch : branch_id (number) , name (text) , open_year (text) , address_road (text) , city (text) , membership_amount (text) | membership_register_branch : member_id (number) , branch_id (text) , register_year (text) | purchase : member_id (number) , branch_id (text) , year (text) , total_pounds (number)

member : card_number (text) , hometown (text)


Question: Find the number of students in total.

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: How many students are there in total?

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: Find the distinct number of president votes.

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: How many distinct president votes are recorded?

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: Find the maximum age of all the students.

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: What is the oldest age among the students?

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: Find the last names of students with major 50.

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)


Question: What are the last names of students studying major 50?

student : stuid (number) , lname (text) , fname (text) , age (number) , sex (text) , major (number) , advisor (number) , city_code (text) | voting_record : stuid (number) , registration_date (text) , election_cycle (text) , president_vote (number) , vice_president_vote (number) , secretary_vote (number) , treasurer_vote (number) , class_president_vote (number) , class_senator_vote (number)