target-benchmark/spider-queries huggingface dataset:
Database: shop_membership (tables: membership_register_branch, member, branch)
Question: Find the name of branches where have some members whose hometown is in Louisville, Kentucky and some in Hiram, Georgia.
SQL: SELECT T2.name FROM membership_register_branch AS T1 JOIN branch AS T2 ON T1.branch_id  =  T2.branch_id JOIN member AS T3 ON T1.member_id  =  T3.member_id WHERE T3.Hometown  =  'Louisville ,  Kentucky' INTERSECT SELECT T2.name FROM membership_register_branch AS T1 JOIN branch AS T2 ON T1.branch_id  =  T2.branch_id JOIN member AS T3 ON T1.member_id  =  T3.member_id WHERE T3.Hometown  =  'Hiram ,  Georgia'
Database: shop_membership (tables: membership_register_branch, member, branch)
Question: What are the names of the branches that have some members with a hometown in Louisville, Kentucky and also those from Hiram, Goergia?
SQL: SELECT T2.name FROM membership_register_branch AS T1 JOIN branch AS T2 ON T1.branch_id  =  T2.branch_id JOIN member AS T3 ON T1.member_id  =  T3.member_id WHERE T3.Hometown  =  'Louisville ,  Kentucky' INTERSECT SELECT T2.name FROM membership_register_branch AS T1 JOIN branch AS T2 ON T1.branch_id  =  T2.branch_id JOIN member AS T3 ON T1.member_id  =  T3.member_id WHERE T3.Hometown  =  'Hiram ,  Georgia'
Database: shop_membership (tables: member)
Question: list the card number of all members whose hometown address includes word "Kentucky".
SQL: SELECT card_number FROM member WHERE Hometown LIKE "%Kentucky%"
Database: shop_membership (tables: member)
Question: What are the card numbers of members from Kentucky?
SQL: SELECT card_number FROM member WHERE Hometown LIKE "%Kentucky%"
Database: voter_2 (tables: student)
Question: Find the number of students in total.
SQL: SELECT count(*) FROM STUDENT
Database: voter_2 (tables: student)
Question: How many students are there in total?
SQL: SELECT count(*) FROM STUDENT
Database: voter_2 (tables: voting_record)
Question: Find the number of voting records in total.
SQL: SELECT count(*) FROM VOTING_RECORD
Database: voter_2 (tables: voting_record)
Question: How many voting records do we have?
SQL: SELECT count(*) FROM VOTING_RECORD
Database: voter_2 (tables: voting_record)
Question: Find the distinct number of president votes.
SQL: SELECT count(DISTINCT President_Vote) FROM VOTING_RECORD
Database: voter_2 (tables: voting_record)
Question: How many distinct president votes are recorded?
SQL: SELECT count(DISTINCT President_Vote) FROM VOTING_RECORD
Database: voter_2 (tables: student)
Question: Find the maximum age of all the students.
SQL: SELECT max(Age) FROM STUDENT
Database: voter_2 (tables: student)
Question: What is the oldest age among the students?
SQL: SELECT max(Age) FROM STUDENT
Database: voter_2 (tables: student)
Question: Find the last names of students with major 50.
SQL: SELECT LName FROM STUDENT WHERE Major  =  50
Database: voter_2 (tables: student)
Question: What are the last names of students studying major 50?
SQL: SELECT LName FROM STUDENT WHERE Major  =  50
Database: voter_2 (tables: student)
Question: Find the first names of students with age above 22.
SQL: SELECT Fname FROM STUDENT WHERE Age  >  22
Database: voter_2 (tables: student)
Question: What are the first names of all the students aged above 22?
SQL: SELECT Fname FROM STUDENT WHERE Age  >  22
Database: voter_2 (tables: student)
Question: What are the majors of male (sex is M) students?
SQL: SELECT Major FROM STUDENT WHERE Sex  =  "M"
Database: voter_2 (tables: student)
Question: List the major of each male student.
SQL: SELECT Major FROM STUDENT WHERE Sex  =  "M"
Database: voter_2 (tables: student)
Question: What is the average age of female (sex is F) students?
SQL: SELECT avg(Age) FROM STUDENT WHERE Sex  =  "F"
Database: voter_2 (tables: student)
Question: Find the average age of female students.
SQL: SELECT avg(Age) FROM STUDENT WHERE Sex  =  "F"
Database: voter_2 (tables: student)
Question: What are the maximum and minimum age of students with major 600?
SQL: SELECT max(Age) ,  min(Age) FROM STUDENT WHERE Major  =  600
Database: voter_2 (tables: student)
Question: Tell me the ages of the oldest and youngest students studying major 600.
SQL: SELECT max(Age) ,  min(Age) FROM STUDENT WHERE Major  =  600
Database: voter_2 (tables: student)
Question: Who are the advisors for students that live in a city with city code "BAL"?
SQL: SELECT Advisor FROM STUDENT WHERE city_code  =  "BAL"
Database: voter_2 (tables: student)
Question: Show the advisors of the students whose city of residence has city code "BAL".
SQL: SELECT Advisor FROM STUDENT WHERE city_code  =  "BAL"
Database: voter_2 (tables: voting_record)
Question: What are the distinct secretary votes in the fall election cycle?
SQL: SELECT DISTINCT Secretary_Vote FROM VOTING_RECORD WHERE ELECTION_CYCLE  =  "Fall"
Database: voter_2 (tables: voting_record)
Question: Return all the distinct secretary votes made in the fall election cycle.
SQL: SELECT DISTINCT Secretary_Vote FROM VOTING_RECORD WHERE ELECTION_CYCLE  =  "Fall"
Database: voter_2 (tables: voting_record)
Question: What are the distinct president votes on 08/30/2015?
SQL: SELECT DISTINCT PRESIDENT_Vote FROM VOTING_RECORD WHERE Registration_Date  =  "08/30/2015"
Database: voter_2 (tables: voting_record)
Question: Show all the distinct president votes made on 08/30/2015.
SQL: SELECT DISTINCT PRESIDENT_Vote FROM VOTING_RECORD WHERE Registration_Date  =  "08/30/2015"
Database: voter_2 (tables: voting_record)
Question: Report the distinct registration date and the election cycle.
SQL: SELECT DISTINCT Registration_Date ,  Election_Cycle FROM VOTING_RECORD
Database: voter_2 (tables: voting_record)
Question: What are the distinct registration dates and the election cycles?
SQL: SELECT DISTINCT Registration_Date ,  Election_Cycle FROM VOTING_RECORD
Database: voter_2 (tables: voting_record)
Question: Report the distinct president vote and the vice president vote.
SQL: SELECT DISTINCT President_Vote ,  VICE_President_Vote FROM VOTING_RECORD
Database: voter_2 (tables: voting_record)
Question: List all the distinct president votes and the vice president votes.
SQL: SELECT DISTINCT President_Vote ,  VICE_President_Vote FROM VOTING_RECORD
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct last names of the students who have class president votes.
SQL: SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.CLASS_President_VOTE
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct last names of the students who have class president votes?
SQL: SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.CLASS_President_VOTE
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct first names of the students who have class senator votes.
SQL: SELECT DISTINCT T1.Fname FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.CLASS_Senator_VOTE
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct first names of the students who have class president votes?
SQL: SELECT DISTINCT T1.Fname FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.CLASS_Senator_VOTE
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct ages of students who have secretary votes in the fall election cycle.
SQL: SELECT DISTINCT T1.Age FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.Secretary_Vote WHERE T2.Election_Cycle  =  "Fall"
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct ages of students who have secretary votes in the fall election cycle?
SQL: SELECT DISTINCT T1.Age FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.Secretary_Vote WHERE T2.Election_Cycle  =  "Fall"
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct Advisor of students who have treasurer votes in the spring election cycle.
SQL: SELECT DISTINCT T1.Advisor FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.Treasurer_Vote WHERE T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: Who served as an advisor for students who have treasurer votes in the spring election cycle?
SQL: SELECT DISTINCT T1.Advisor FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.Treasurer_Vote WHERE T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct majors of students who have treasurer votes.
SQL: SELECT DISTINCT T1.Major FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.Treasurer_Vote
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct majors that students with treasurer votes are studying?
SQL: SELECT DISTINCT T1.Major FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.Treasurer_Vote
Database: voter_2 (tables: voting_record, student)
Question: Find the first and last names of all the female (sex is F) students who have president votes.
SQL: SELECT DISTINCT T1.Fname ,  T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.President_VOTE WHERE T1.sex  =  "F"
Database: voter_2 (tables: voting_record, student)
Question: What are the first and last names of all the female students who have president votes?
SQL: SELECT DISTINCT T1.Fname ,  T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.President_VOTE WHERE T1.sex  =  "F"
Database: voter_2 (tables: voting_record, student)
Question: Find the first and last name of all the students of age 18 who have vice president votes.
SQL: SELECT DISTINCT T1.Fname ,  T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.VICE_President_VOTE WHERE T1.age  =  18
Database: voter_2 (tables: voting_record, student)
Question: What are the first names and last names of the students who are 18 years old and have vice president votes.
SQL: SELECT DISTINCT T1.Fname ,  T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.VICE_President_VOTE WHERE T1.age  =  18
Database: voter_2 (tables: voting_record, student)
Question: How many male (sex is M) students have class senator votes in the fall election cycle?
SQL: SELECT count(*) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  Class_Senator_Vote WHERE T1.Sex  =  "M" AND T2.Election_Cycle  =  "Fall"
Database: voter_2 (tables: voting_record, student)
Question: Count the number of male students who had class senator votes in the fall election cycle.
SQL: SELECT count(*) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  Class_Senator_Vote WHERE T1.Sex  =  "M" AND T2.Election_Cycle  =  "Fall"
Database: voter_2 (tables: voting_record, student)
Question: Find the number of students whose city code is NYC and who have class senator votes in the spring election cycle.
SQL: SELECT count(*) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  Class_Senator_Vote WHERE T1.city_code  =  "NYC" AND T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: Which students live in the city with code "NYC" and have class senator votes in the spring election cycle? Count the numbers.
SQL: SELECT count(*) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  Class_Senator_Vote WHERE T1.city_code  =  "NYC" AND T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: Find the average age of students who live in the city with code "NYC" and have secretary votes in the spring election cycle.
SQL: SELECT avg(T1.Age) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  SECRETARY_Vote WHERE T1.city_code  =  "NYC" AND T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: What is the average age of students who have city code "NYC" and have secretary votes for the spring election cycle?
SQL: SELECT avg(T1.Age) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  SECRETARY_Vote WHERE T1.city_code  =  "NYC" AND T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: Find the average age of female (sex is F) students who have secretary votes in the spring election cycle.
SQL: SELECT avg(T1.Age) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  SECRETARY_Vote WHERE T1.Sex  =  "F" AND T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: What is the average age of the female students with secretary votes in the spring election cycle?
SQL: SELECT avg(T1.Age) FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  SECRETARY_Vote WHERE T1.Sex  =  "F" AND T2.Election_Cycle  =  "Spring"
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct first names of all the students who have vice president votes and whose city code is not PIT.
SQL: SELECT DISTINCT T1.Fname FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.VICE_PRESIDENT_Vote EXCEPT SELECT DISTINCT Fname FROM STUDENT WHERE city_code  =  "PIT"
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct first names of the students who have vice president votes and reside in a city whose city code is not PIT?
SQL: SELECT DISTINCT T1.Fname FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  T2.VICE_PRESIDENT_Vote EXCEPT SELECT DISTINCT Fname FROM STUDENT WHERE city_code  =  "PIT"
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct last names of all the students who have president votes and whose advisor is not 2192.
SQL: SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  PRESIDENT_Vote EXCEPT SELECT DISTINCT LName FROM STUDENT WHERE Advisor  =  "2192"
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct last names of the students who have president votes but do not have 2192 as the advisor?
SQL: SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  PRESIDENT_Vote EXCEPT SELECT DISTINCT LName FROM STUDENT WHERE Advisor  =  "2192"
Database: voter_2 (tables: voting_record, student)
Question: Find the distinct last names of all the students who have president votes and whose advisor is 8741.
SQL: SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  PRESIDENT_Vote INTERSECT SELECT DISTINCT LName FROM STUDENT WHERE Advisor  =  "8741"
Database: voter_2 (tables: voting_record, student)
Question: What are the distinct last names of the students who have president votes and have 8741 as the advisor?
SQL: SELECT DISTINCT T1.LName FROM STUDENT AS T1 JOIN VOTING_RECORD AS T2 ON T1.StuID  =  PRESIDENT_Vote INTERSECT SELECT DISTINCT LName FROM STUDENT WHERE Advisor  =  "8741"
Database: voter_2 (tables: student)
Question: For each advisor, report the total number of students advised by him or her.
SQL: SELECT Advisor ,  count(*) FROM STUDENT GROUP BY Advisor
Database: voter_2 (tables: student)
Question: How many students does each advisor have?
SQL: SELECT Advisor ,  count(*) FROM STUDENT GROUP BY Advisor
Database: voter_2 (tables: student)
Question: Report all advisors that advise more than 2 students.
SQL: SELECT Advisor FROM STUDENT GROUP BY Advisor HAVING COUNT(*)  >  2
Database: voter_2 (tables: student)
Question: Which advisors have more than two students?
SQL: SELECT Advisor FROM STUDENT GROUP BY Advisor HAVING COUNT(*)  >  2
Database: voter_2 (tables: student)
Question: Report all majors that have less than 3 students.
SQL: SELECT Major FROM STUDENT GROUP BY Major HAVING COUNT(*)  <  3
Database: voter_2 (tables: student)
Question: What are the majors only less than three students are studying?
SQL: SELECT Major FROM STUDENT GROUP BY Major HAVING COUNT(*)  <  3
Database: voter_2 (tables: voting_record)
Question: For each election cycle, report the number of voting records.
SQL: SELECT Election_Cycle ,  count(*) FROM VOTING_RECORD GROUP BY Election_Cycle
Database: voter_2 (tables: voting_record)
Question: Count the number of voting records for each election cycle.
SQL: SELECT Election_Cycle ,  count(*) FROM VOTING_RECORD GROUP BY Election_Cycle
Database: voter_2 (tables: student)
Question: Which major has the most students?
SQL: SELECT Major FROM STUDENT GROUP BY major ORDER BY count(*) DESC LIMIT 1
Database: voter_2 (tables: student)
Question: Find the major that is studied by the largest number of students.
SQL: SELECT Major FROM STUDENT GROUP BY major ORDER BY count(*) DESC LIMIT 1
Database: voter_2 (tables: student)
Question: What is the most common major among female (sex is F) students?
SQL: SELECT Major FROM STUDENT WHERE Sex  =  "F" GROUP BY major ORDER BY count(*) DESC LIMIT 1
Database: voter_2 (tables: student)
Question: Find the major that is studied by the most female students.
SQL: SELECT Major FROM STUDENT WHERE Sex  =  "F" GROUP BY major ORDER BY count(*) DESC LIMIT 1
Database: voter_2 (tables: student)
Question: What is the city_code of the city that the most students live in?
SQL: SELECT city_code FROM STUDENT GROUP BY city_code ORDER BY count(*) DESC LIMIT 1
Database: voter_2 (tables: student)
Question: Return the code of the city that has the most students.
SQL: SELECT city_code FROM STUDENT GROUP BY city_code ORDER BY count(*) DESC LIMIT 1
Database: voter_2 (tables: student)
Question: Report the distinct advisors who have more than 2 students.
SQL: SELECT Advisor FROM STUDENT GROUP BY Advisor HAVING count(*)  >  2
Database: voter_2 (tables: student)
Question: Which advisors are advising more than 2 students?
SQL: SELECT Advisor FROM STUDENT GROUP BY Advisor HAVING count(*)  >  2
Database: products_gen_characteristics (tables: products)
Question: How many products are there?
SQL: SELECT count(*) FROM products
Database: products_gen_characteristics (tables: products)
Question: Count the number of products.
SQL: SELECT count(*) FROM products
Database: products_gen_characteristics (tables: ref_colors)
Question: How many colors are there?
SQL: SELECT count(*) FROM ref_colors
Database: products_gen_characteristics (tables: ref_colors)
Question: Count the number of colors.
SQL: SELECT count(*) FROM ref_colors
Database: products_gen_characteristics (tables: characteristics)
Question: How many characteristics are there?
SQL: SELECT count(*) FROM CHARACTERISTICS
Database: products_gen_characteristics (tables: characteristics)
Question: Count the number of characteristics.
SQL: SELECT count(*) FROM CHARACTERISTICS
Database: products_gen_characteristics (tables: products)
Question: What are the names and buying prices of all the products?
SQL: SELECT product_name ,  typical_buying_price FROM products
Database: products_gen_characteristics (tables: products)
Question: Return the names and typical buying prices for all products.
SQL: SELECT product_name ,  typical_buying_price FROM products
Database: products_gen_characteristics (tables: ref_colors)
Question: List the description of all the colors.
SQL: SELECT color_description FROM ref_colors
Database: products_gen_characteristics (tables: ref_colors)
Question: What are the descriptions for each color?
SQL: SELECT color_description FROM ref_colors
Database: products_gen_characteristics (tables: characteristics)
Question: Find the names of all the product characteristics.
SQL: SELECT DISTINCT characteristic_name FROM CHARACTERISTICS
Database: products_gen_characteristics (tables: characteristics)
Question: What are the different names of the product characteristics?
SQL: SELECT DISTINCT characteristic_name FROM CHARACTERISTICS
Database: products_gen_characteristics (tables: products)
Question: What are the names of products with category "Spices"?
SQL: SELECT product_name FROM products WHERE product_category_code  =  "Spices"
Database: products_gen_characteristics (tables: products)
Question: Return the names of products in the category 'Spices'.
SQL: SELECT product_name FROM products WHERE product_category_code  =  "Spices"
Database: products_gen_characteristics (tables: ref_colors, products)
Question: List the names, color descriptions and product descriptions of products with category "Herbs".
SQL: SELECT T1.product_name ,  T2.color_description ,  T1.product_description FROM products AS T1 JOIN Ref_colors AS T2 ON T1.color_code  =  T2.color_code WHERE product_category_code  =  "Herbs"
Database: products_gen_characteristics (tables: ref_colors, products)
Question: What are the names, color descriptions, and product descriptions for products in the 'Herbs' category?
SQL: SELECT T1.product_name ,  T2.color_description ,  T1.product_description FROM products AS T1 JOIN Ref_colors AS T2 ON T1.color_code  =  T2.color_code WHERE product_category_code  =  "Herbs"
Database: products_gen_characteristics (tables: products)
Question: How many products are there under the category "Seeds"?
SQL: SELECT count(*) FROM products WHERE product_category_code  =  "Seeds"
Database: products_gen_characteristics (tables: products)
Question: Count the number of products in the category 'Seeds'.
SQL: SELECT count(*) FROM products WHERE product_category_code  =  "Seeds"
Database: products_gen_characteristics (tables: products)
Question: Find the number of products with category "Spices" and typically sold above 1000.
SQL: SELECT count(*) FROM products WHERE product_category_code  =  "Spices" AND typical_buying_price  >  1000
Database: products_gen_characteristics (tables: products)
Question: How many products are in the 'Spices' category and have a typical price of over 1000?
SQL: SELECT count(*) FROM products WHERE product_category_code  =  "Spices" AND typical_buying_price  >  1000
Database: products_gen_characteristics (tables: products)
Question: What is the category and typical buying price  of the product with name "cumin"?
SQL: SELECT product_category_code ,  typical_buying_price FROM products WHERE product_name  =  "cumin"
Database: products_gen_characteristics (tables: products)
Question: Return the category code and typical price of 'cumin'.
SQL: SELECT product_category_code ,  typical_buying_price FROM products WHERE product_name  =  "cumin"
Database: products_gen_characteristics (tables: products)
Question: Which category does the product named "flax" belong to?
SQL: SELECT product_category_code FROM products WHERE product_name  =  "flax"
Database: products_gen_characteristics (tables: products)
Question: What is the code of the category that the product with the name 'flax' belongs to?
SQL: SELECT product_category_code FROM products WHERE product_name  =  "flax"
Database: products_gen_characteristics (tables: ref_colors, products)
Question: What is the name of the product with the color description 'yellow'?
SQL: SELECT T1.product_name FROM products AS T1 JOIN ref_colors AS T2 ON T1.color_code  =  T2.color_code WHERE T2.color_description  =  'yellow'
Database: products_gen_characteristics (tables: ref_colors, products)
Question: Give the name of the products that have a color description 'yellow'.
SQL: SELECT T1.product_name FROM products AS T1 JOIN ref_colors AS T2 ON T1.color_code  =  T2.color_code WHERE T2.color_description  =  'yellow'
Database: products_gen_characteristics (tables: products, ref_product_categories)
Question: Find the category descriptions of the products whose descriptions include letter 't'.
SQL: SELECT T1.product_category_description FROM ref_product_categories AS T1 JOIN products AS T2 ON T1.product_category_code  =  T2.product_category_code WHERE T2.product_description LIKE '%t%'
Database: products_gen_characteristics (tables: products, ref_product_categories)
Question: What are the descriptions of the categories that products with product descriptions that contain the letter t are in?
SQL: SELECT T1.product_category_description FROM ref_product_categories AS T1 JOIN products AS T2 ON T1.product_category_code  =  T2.product_category_code WHERE T2.product_description LIKE '%t%'
Database: products_gen_characteristics (tables: ref_colors, products)
Question: What is the color description of the product with name "catnip"?
SQL: SELECT t2.color_description FROM products AS t1 JOIN ref_colors AS t2 ON t1.color_code  =  t2.color_code WHERE t1.product_name  =  "catnip"