Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT ClubName, ClubID, ClubDesc FROM Club WHERE "ClubID" != 4 AND ClubName != "Tennis Club" OR ClubDesc != "A competitive tennis club." OR ClubLocation <> "HHH" EXCEPT SELECT ClubName, ClubID, ClubDesc FROM Club WHERE "ClubID" >= 4

Refurbish computers; teach kids and adults about computer basics.

Venture capital fund for student business.

Pen and Paper Gaming
3
Play pen and paper games on campus.


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 4 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT employee_id FROM Circulation_History WHERE "copy_number" <> 15 UNION ALL SELECT employee_id FROM Employees WHERE other_details <> "b" OR "employee_id" >= 5 AND role_code <> "ED" OR employee_name = "Clemens"


Question: SELECT Template_Type_Code, Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Description <> "Paper" INTERSECT SELECT Template_Type_Code, Template_Type_Description FROM Ref_Template_Types WHERE Template_Type_Code = "AD"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3


Question: SELECT Name FROM member WHERE "Member_ID" != 1 UNION SELECT Name FROM member WHERE Hometown = "Louisville, Kentucky"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 5 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 12 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 10


Question: SELECT Writer FROM book WHERE Title != "Bloody Mary : Lady Liberty" OR "Issues" > 1.0 NOT IN (SELECT Writer FROM book WHERE "Book_ID" >= 2 AND Writer = "Howard Chaykin")


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT MIN(Driver_ID) FROM driver WHERE "Driver_ID" >= 1 EXCEPT SELECT MIN(Driver_ID) FROM school_bus WHERE "Driver_ID" < 3 AND "Years_Working" <> 10 AND "School_ID" != 4 OR If_full_time != "T"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT shipping_agent_code FROM Documents WHERE "document_id" < 20 OR receipt_date <> "1996-05-31 06:51:58" AND receipt_number <> "189" EXCEPT SELECT shipping_agent_code FROM Ref_Shipping_Agents WHERE shipping_agent_code <> "FE" AND shipping_agent_name != "USPS"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 3 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT AVG(feature_type_name) FROM Ref_Feature_Types WHERE feature_type_code <> "Security" OR feature_type_name = "Securiyt, eg Burglar Alarm." INTERSECT SELECT AVG(feature_type_name) FROM Ref_Feature_Types WHERE feature_type_code = "Amenity"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT aid FROM aircraft WHERE "aid" <> 11 AND "distance" <= 8430 GROUP BY aid HAVING aid > 10 EXCEPT SELECT aid FROM aircraft WHERE name <> "Airbus A320" AND "distance" = 2128 GROUP BY aid HAVING aid <= 6


Question: SELECT AVG(Coach_ID) FROM coach WHERE Gender <> "M" OR "Rank" > 2 UNION ALL SELECT AVG(Coach_ID) FROM player_coach WHERE "Starting_year" <= 2013 AND "Player_ID" <= 6


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT Maker, MIN(ModelId), Model FROM model_list WHERE "Maker" != 16 OR "ModelId" <= 10 OR Model != "volvo" UNION SELECT Maker, MIN(ModelId), Model FROM model_list WHERE "ModelId" >= 35 OR "Maker" != 4 AND Model = "buick"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT AVG(u_id) FROM useracct WHERE "u_id" > 7 AND name = "Helen" EXCEPT SELECT AVG(u_id) FROM useracct WHERE "u_id" > 6


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 12 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT AVG(Employee_ID) FROM evaluation WHERE "Bonus" >= 2900.0 OR Year_awarded = "2015" UNION ALL SELECT AVG(Employee_ID) FROM hiring WHERE "Employee_ID" != 1 AND Is_full_time = "T" OR Start_from = "2011"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Employee_ID FROM employee WHERE "Age" <= 23 OR "Employee_ID" >= 1 UNION SELECT Employee_ID FROM evaluation WHERE "Bonus" = 3000.0


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 7 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT feature_type_name FROM Ref_Feature_Types WHERE feature_type_code <> "Amenity" UNION ALL SELECT feature_type_name FROM Ref_Feature_Types WHERE feature_type_name != "Securiyt, eg Burglar Alarm." OR feature_type_code = "Security"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2


Question: SELECT Other_Details FROM Documents WHERE "Document_ID" >= 80 AND Document_Name = "Introduction of OS" AND Other_Details <> "None" UNION SELECT Other_Details FROM Paragraphs WHERE "Paragraph_ID" < 608931827


Question: SELECT Store_ID FROM store WHERE "Area_size" < 26.69 EXCEPT SELECT Store_ID FROM store_district WHERE "Store_ID" = 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 6 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 7


Question: SELECT i_id FROM item WHERE title != "comb" NOT IN (SELECT i_id FROM item WHERE "i_id" = 1 AND title != "pear")


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Maker FROM model_list WHERE Model != "ford" OR "ModelId" = 16 UNION SELECT Maker FROM model_list WHERE "ModelId" = 13 AND Model <> "chrysler"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT name FROM aircraft WHERE "aid" <= 2 OR "distance" != 30 AND name <> "Boeing 777-300" UNION ALL SELECT name FROM employee WHERE name = "Richard Jackson" OR "eid" <= 310454876


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2


Question: SELECT LName, Fname FROM Student WHERE "Age" >= 18 OR Fname = "Paul" OR Sex = "M" OR LName <> "Schmidt" INTERSECT SELECT LName, Fname FROM Student WHERE "Major" != 50 OR "StuID" > 1015 OR "Advisor" > 7271 AND Sex <> "F" AND Fname != "Dinesh"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 6 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 1


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 9 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 7


Question: SELECT T1.Employee_ID, T2.Bonus FROM employee as T1 JOIN evaluation as T2 ON T1.Employee_ID == T2.Employee_ID GROUP BY Bonus HAVING Year_awarded <> "2011" OR Name = "Matt Stevens" AND Age > 23


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1


Question: SELECT distance, departure_date, AVG(origin), COUNT(destination), arrival_date FROM flight WHERE "flno" > 34 OR "price" <> 182.0 OR "aid" = 7 AND arrival_date = "04/12/2005 12:02" AND origin != "Los Angeles" AND "distance" >= 1749 AND destination <> "Dallas" INTERSECT SELECT distance, departure_date, AVG(origin), COUNT(destination), arrival_date FROM flight WHERE "aid" >= 1 OR "distance" = 2551 AND departure_date <> "04/12/2005 06:30" OR origin = "Chicago"


Question: SELECT MAX(document_id) FROM Circulation_History WHERE "document_id" > 1 OR "employee_id" >= 8 AND "draft_number" > 1 EXCEPT SELECT MAX(document_id) FROM Document_Drafts WHERE "document_id" >= 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 12 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 9 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Store_Name, Number_of_product_category FROM store WHERE Type = "Village Store" AND "Store_ID" > 2 AND "Area_size" <> 7.23 OR "Number_of_product_category" != 17811.0 OR "Ranking" > 1 OR Store_Name != "Doaktown" UNION SELECT Store_Name, Number_of_product_category FROM store WHERE "Number_of_product_category" < 1170.0 AND Type != "City Mall"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3


Question: SELECT customer_status_code, phone_number, MIN(email_address), last_name FROM Customers WHERE "customer_address_id" <> 10 AND "customer_id" >= 7 OR email_address <> "kitty.hand@example.net" AND date_of_birth = "1998-12-15 13:24:40" AND date_became_customer = "2016-04-08 00:28:15" AND last_name <> "Ortiz" OR cell_mobile_phone_number <> "00659133944" OR phone_number = "(729)396-4354x3576" AND customer_status_code = "Good Customer" AND "amount_outstanding" <= 7093.0 INTERSECT SELECT customer_status_code, phone_number, MIN(email_address), last_name FROM Customers WHERE first_name = "Marina" OR date_became_customer <> "2017-10-05 14:15:46" OR "amount_outstanding" != 5687.0 AND date_of_birth != "1994-05-07 01:32:16"


Question: SELECT staff_id FROM Lessons WHERE "lesson_id" != 4 AND lesson_status_code = "Completed" OR "vehicle_id" >= 2 OR lesson_time != "9" OR "staff_id" = 12 AND lesson_date != "2018-03-16 07:08:52" EXCEPT SELECT staff_id FROM Staff WHERE last_name <> "Herzog" OR date_left_staff = "2018-03-06 23:17:41" AND middle_name != "Duane"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT price, lesson_id, lesson_time FROM Lessons WHERE lesson_status_code <> "Cancelled" AND lesson_date <> "2018-03-17 19:02:07" AND "customer_id" != 3 OR "vehicle_id" <= 1 AND "price" = 277.0 AND "staff_id" >= 12 UNION SELECT price, lesson_id, lesson_time FROM Lessons WHERE "price" != 199.0 AND "lesson_id" >= 9 AND "customer_id" > 11 OR "staff_id" >= 11


Question: SELECT COUNT(Governor), Party_ID, COUNT(Lieutenant_Governor), Year, SUM(Attorney_General) FROM party WHERE Comptroller <> "Carl McCall" OR Party != "Democratic" AND US_Senate <> "Hillary Rodham Clinton" AND Lieutenant_Governor <> "Jonathan Reiter" AND "Party_ID" = 7 OR Governor <> "Carl McCall" OR Attorney_General != "Eliot Spitzer" UNION SELECT COUNT(Governor), Party_ID, COUNT(Lieutenant_Governor), Year, SUM(Attorney_General) FROM party WHERE Lieutenant_Governor <> "David Paterson" AND US_Senate <> "Hillary Rodham Clinton" AND Governor <> "Peter Vallone" OR "Year" < 2006.0 OR Attorney_General != "Andrew Cuomo" AND Party != "Liberal"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3


Question: SELECT Name FROM employee WHERE "Employee_ID" = 1 AND City <> "Wasps" OR "Age" > 29 OR Name != "Louis Deacon" INTERSECT SELECT Name FROM employee WHERE Name = "Andrew Sheridan" AND City = "Wasps" OR "Age" != 32


Question: SELECT MAX(document_id) FROM Document_Drafts WHERE "document_id" <> 7 AND "draft_number" <= 10 EXCEPT SELECT MAX(document_id) FROM Documents WHERE receipt_date != "1982-09-27 14:52:15" AND document_type_code != "Hard Drive" OR receipt_number <> "114" AND shipping_agent_code != "FE" OR other_details != "z" OR "document_id" < 14


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Num_Employees, AVG(Name), Department_ID FROM department WHERE "Budget_in_Billions" = 46.2 AND Name <> "Health and Human Services" AND "Num_Employees" <= 235000.0 UNION ALL SELECT Num_Employees, AVG(Name), Department_ID FROM department WHERE "Num_Employees" <= 67000.0 OR "Department_ID" > 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT SUM(shipping_agent_description) FROM Ref_Shipping_Agents WHERE shipping_agent_description != "w" UNION SELECT SUM(shipping_agent_description) FROM Ref_Shipping_Agents WHERE shipping_agent_name <> "UPS"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 6 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Incorporated_in, Type FROM operate_company WHERE "Group_Equity_Shareholding" != 40.0 OR Principal_activities <> "Ground handling" AND Type <> "Joint Venture" AND name = "Air China Cargo" OR "id" > 10 AND Incorporated_in != "Hong Kong" EXCEPT SELECT Incorporated_in, Type FROM operate_company WHERE Type = "Joint Venture" AND "id" >= 10


Question: SELECT SUM(Party) FROM election WHERE "Party" < 1 AND "Election_ID" = 5 EXCEPT SELECT SUM(Party) FROM party WHERE Attorney_General <> "Jeanine Pirro" AND "Year" > 2006.0 AND Governor <> "Carl McCall" OR Lieutenant_Governor != "Sandra Frankel" AND Party = "Independence" OR US_Senate <> "Charles Schumer" AND "Party_ID" != 4 OR Comptroller != "Alan Hevesi"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT SUM(document_type_code) FROM Documents WHERE shipping_agent_code <> "UP" AND document_type_code <> "Paper" OR receipt_number <> "114" AND other_details = "p" AND document_status_code != "done" AND "document_id" = 1 UNION ALL SELECT SUM(document_type_code) FROM Ref_Document_Types WHERE document_type_code != "CD"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 1


Question: SELECT Club_ID FROM coach WHERE Coach_name <> "Jameson Tomas" UNION ALL SELECT Club_ID FROM match_result WHERE "Bronze" != 10 AND "Small_Silver" > 4 AND "Big_Silver" <> 12 OR "Club_ID" <> 1 AND "Points" > 102 AND "Gold" <> 20 OR "Rank" = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT eid FROM certificate WHERE "eid" != 142519864 OR "aid" < 7 EXCEPT SELECT eid FROM employee WHERE "eid" != 567354612 AND "salary" = 289950


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT Store_ID FROM store WHERE Store_Name != "Miramichi" AND "Store_ID" <> 3 OR "Ranking" != 3 UNION ALL SELECT Store_ID FROM store_product WHERE "Product_ID" <= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2


Question: SELECT Driver_ID FROM driver WHERE Home_city != "Bethel" AND Party != "Dem" OR Name != "Timothy Ackert" AND "Driver_ID" > 8 OR "Age" = 38 EXCEPT SELECT Driver_ID FROM school_bus WHERE "School_ID" > 1 AND "Driver_ID" <> 10 AND If_full_time != "F"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 5 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT contestant_number FROM CONTESTANTS WHERE "contestant_number" = 8 UNION ALL SELECT contestant_number FROM CONTESTANTS WHERE contestant_name != "Loraine NygrenTania Mattioli" OR "contestant_number" > 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT vehicle_id FROM Lessons WHERE lesson_date <> "2018-02-26 02:36:35" OR "customer_id" != 2 AND lesson_time <> "4" AND "lesson_id" <> 10 AND lesson_status_code != "Cancelled" AND "price" > 199.0 AND "vehicle_id" >= 1 UNION ALL SELECT vehicle_id FROM Vehicles WHERE vehicle_details = "Van"


Question: SELECT AVG(Template_ID) FROM Documents WHERE Other_Details <> "None" AND "Template_ID" <= 25 AND Document_Description <> "y" AND Document_Name <> "Palm reading" UNION ALL SELECT AVG(Template_ID) FROM Templates WHERE Date_Effective_From != "2005-02-20 00:31:34" AND "Template_ID" < 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT MAX(Aircraft_ID) FROM aircraft WHERE Aircraft <> "CH-53E Super Stallion" OR Total_disk_area != "8,495 ft² (789 m²)" INTERSECT SELECT MAX(Aircraft_ID) FROM airport_aircraft WHERE "Aircraft_ID" >= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1


Question: SELECT MIN(School_id) FROM School WHERE "Enrollment" = 316 OR School_name <> "Knox Community" OR IHSAA_Class <> "AA" AND Location = "Bourbon" OR IHSAA_Football_Class <> "AA" OR Mascot = "Trojans" AND County <> "50 Marshall" UNION ALL SELECT MIN(School_id) FROM endowment WHERE "amount" <> 8.85 AND donator_name != "Valverde" OR "endowment_id" < 1 OR "School_id" <= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Date_Effective_From, COUNT(Template_Details), Template_Type_Code, Date_Effective_To FROM Templates WHERE Date_Effective_From != "2012-04-05 07:11:42" AND "Version_Number" <= 5 AND "Template_ID" > 20 AND Date_Effective_To = "2007-06-06 06:18:53" OR Template_Details <> "" OR Template_Type_Code != "PP" EXCEPT SELECT Date_Effective_From, COUNT(Template_Details), Template_Type_Code, Date_Effective_To FROM Templates WHERE "Version_Number" <= 5 OR Template_Type_Code != "AD" AND Date_Effective_To <> "1993-03-24 14:30:23" OR Template_Details != "" OR Date_Effective_From = "1975-10-20 02:28:58"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT id FROM albums WHERE title <> "Handel: Music for the Royal Fireworks (Original Version 1749)" UNION ALL SELECT id FROM playlists WHERE "id" != 18


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 6 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT id FROM flight WHERE "Velocity" <> 135.0 AND "id" < 1 OR Date = "March 28, 1966" OR Pilot = "Peterson" AND Vehicle_Flight_number = "M2-F1 #14" AND "airport_id" > 3 AND "Altitude" = 0.0 UNION ALL SELECT id FROM operate_company WHERE "Group_Equity_Shareholding" != 100.0 OR "id" > 10 AND Type != "Joint Venture"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Continent FROM continents WHERE "ContId" != 1 UNION ALL SELECT Continent FROM countries WHERE CountryName != "new zealand"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 1 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Club_name, Region FROM club WHERE "Club_ID" = 2 AND Club_name != "Helsingborgs IF" OR "Start_year" <= 2005 UNION SELECT Club_name, Region FROM club WHERE "Club_ID" > 1 OR "Start_year" <> 2005 AND Region = "Korea"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT property_type_description, property_type_code FROM Ref_Property_Types WHERE property_type_code = "Field" AND property_type_description <> "House, Bungalow, etc." EXCEPT SELECT property_type_description, property_type_code FROM Ref_Property_Types WHERE property_type_code = "Shop"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 7 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 3 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


Question: SELECT MIN(Branch_ID) FROM branch WHERE "Branch_ID" > 8 OR Open_year <> "2009" AND City <> "London" AND membership_amount <> "91" AND Name != "Cochrane" UNION SELECT MIN(Branch_ID) FROM purchase WHERE Year = "2017" OR Branch_ID = "5" OR "Member_ID" <> 3 OR "Total_pounds" < 321.13


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 7 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT Sales_in_Billion, Assets_in_Billion, Industry FROM company WHERE "Assets_in_Billion" > 340.5 AND Headquarters <> "China" AND Industry <> "Banking" OR Name <> "Gazprom" AND "Company_ID" = 13.0 OR "Sales_in_Billion" = 102.0 UNION SELECT Sales_in_Billion, Assets_in_Billion, Industry FROM company WHERE "Sales_in_Billion" > 447.0 OR "Profits_in_Billion" != 21.5 OR Industry = "Banking" OR Name != "Gazprom" OR "Company_ID" = 10.0 AND Headquarters = "USA" AND "Market_Value_in_Billion" != 79.5


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT MIN(T1.id), T2.Pilot FROM airport as T1 JOIN flight as T2 ON T1.id = T2.id WHERE IATA = "BLL" AND MIN(Altitude) <> 3650.0 OR airport_id <> 1 OR name = "Bergen Airport" OR MIN(company_id) >= 11 AND Country = "Belgium" OR MIN(Velocity) <> 240.0 AND Date = "October 25, 1963" OR City = "Akureyri" OR Pilot <> "Thompson"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT MIN(T1.Aircraft_ID), T2.Airport_ID FROM aircraft as T1 JOIN airport_aircraft as T2 ON T1.Aircraft_ID = T2.Aircraft_ID WHERE "Airport_ID" <> 9 GROUP BY Max_Gross_Weight HAVING Description = "Tandem rotor helicopter" AND Aircraft <> "CH-47D Chinook" AND Max_disk_Loading <> "14.5 lb/ft² (71 kg/m²)" OR Airport_ID < 9


Question: SELECT Template_Details, AVG(Date_Effective_From), SUM(Template_Type_Code), AVG(Version_Number), Template_ID FROM Templates WHERE "Version_Number" = 4 AND Date_Effective_To <> "1976-10-28 10:08:50" UNION ALL SELECT Template_Details, AVG(Date_Effective_From), SUM(Template_Type_Code), AVG(Version_Number), Template_ID FROM Templates WHERE "Template_ID" < 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 1


Question: SELECT Continent FROM continents WHERE "ContId" <= 1 UNION ALL SELECT Continent FROM countries WHERE CountryName <> "uk" AND "CountryId" >= 3 AND "Continent" >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 2 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 10


Question: SELECT name FROM employee WHERE "eid" >= 269734834 AND name != "Lisa Walker" OR "salary" > 152013 UNION SELECT name FROM employee WHERE "eid" >= 287321212


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT Club_ID FROM club WHERE Region <> "USA" AND "Club_ID" = 6 OR Club_name <> "BK Häcken" UNION SELECT Club_ID FROM match_result WHERE "Small_Silver" = 4 OR "Bronze" < 8 AND "Points" != 102 OR "Rank" = 6 OR "Club_ID" >= 1 OR "Big_Silver" != 14


Question: SELECT feature_type_code FROM Other_Available_Features WHERE feature_name <> "Pool" EXCEPT SELECT feature_type_code FROM Ref_Feature_Types WHERE feature_type_name <> "Securiyt, eg Burglar Alarm."


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT COUNT(Fname), SUM(Major) FROM Student WHERE city_code = "WAS" OR "Age" < 19 UNION ALL SELECT COUNT(Fname), SUM(Major) FROM Student WHERE "StuID" != 1016 AND Fname != "Jandy" OR "Advisor" = 8741 OR Sex = "M" AND "Age" != 22 OR "Major" != 600 AND LName = "Han"


Question: SELECT property_type_code FROM Properties WHERE other_property_details != "None" OR apt_feature_1 != "fuga" OR date_sold != "1998-09-15 05:26:22" OR "agreed_selling_price" != 4201.8 EXCEPT SELECT property_type_code FROM Ref_Property_Types WHERE property_type_code <> "House"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 7


Question: SELECT AVG(ClubName), ClubID, ClubLocation, ClubDesc FROM Club WHERE "ClubID" <> 2 OR ClubLocation != "AKW" OR ClubDesc != "Venture capital fund for student business." INTERSECT SELECT AVG(ClubName), ClubID, ClubLocation, ClubDesc FROM Club WHERE "ClubID" = 1 OR ClubLocation != "AKW"

AVG(ClubName) ClubID ClubLocation ClubDesc

Refurbish computers; teach kids and adults about computer basics.


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT name FROM employee WHERE "eid" <= 242518965 AND "salary" < 114323 OR name = "Betty Adams" UNION SELECT name FROM employee WHERE name != "Chad Stewart" OR "eid" = 90873519


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 11 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 7


Question: SELECT SUM(Coach_ID), Coach_name, AVG(Rank), COUNT(Gender), Club_ID FROM coach WHERE "Club_ID" != 1 AND Gender = "M" OR Coach_name != "James Wong" AND "Coach_ID" != 4 AND "Rank" < 4 EXCEPT SELECT SUM(Coach_ID), Coach_name, AVG(Rank), COUNT(Gender), Club_ID FROM coach WHERE Gender <> "M" AND "Coach_ID" >= 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2


Question: SELECT COUNT(FullName), MIN(Id) FROM car_makers WHERE FullName != "Opel" OR Country <> "1" OR "Id" >= 15 OR Maker <> "gm" INTERSECT SELECT COUNT(FullName), MIN(Id) FROM car_makers WHERE "Id" <> 8 OR Country <> "6" AND FullName != "Opel"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT customer_id FROM Customers WHERE first_name = "Carole" AND cell_mobile_phone_number = "1-387-258-1016x96963" AND date_of_birth = "1988-09-19 14:45:56" OR phone_number <> "1-875-045-0806" AND "customer_address_id" >= 2 OR "customer_id" > 3 AND email_address = "karina.carroll@example.net" OR last_name = "Spinka" AND "amount_outstanding" = 8144.0 AND customer_status_code <> "Good Customer" AND date_became_customer = "2016-03-18 06:14:18" EXCEPT SELECT customer_id FROM Lessons WHERE "lesson_id" >= 9 OR "price" <> 199.0 OR "customer_id" <> 2 AND "staff_id" <> 12 OR lesson_date = "2018-03-07 22:03:49"


Question: SELECT Member_ID FROM member WHERE "Level" >= 6 OR Name != "Jeremy Jarmon" AND Hometown != "Fort Campbell, Kentucky" UNION ALL SELECT Member_ID FROM membership_register_branch WHERE "Member_ID" > 3 OR Branch_ID = "6" OR Register_Year != "2016"


Question: SELECT School_id FROM budget WHERE "total_budget_percent_invested" < 2.0 AND "Invested" < 85249 OR "Budgeted" <> 61283 OR "School_id" >= 2 AND Budget_invested_percent <> "228.6" INTERSECT SELECT School_id FROM endowment WHERE donator_name = "Santiago" AND "School_id" >= 4


Question: SELECT COUNT(Assets_in_Billion), MAX(Profits_in_Billion), Sales_in_Billion, COUNT(Headquarters) FROM company WHERE "Assets_in_Billion" <> 302.6 AND "Market_Value_in_Billion" < 294.7 OR Headquarters = "UK" AND Industry = "Banking" AND "Company_ID" = 17.0 OR "Sales_in_Billion" > 143.7 GROUP BY Sales_in_Billion HAVING COUNT(Assets_in_Billion) > 1 OR MAX(Profits_in_Billion) > 11.1 OR COUNT(Headquarters) < 1 EXCEPT SELECT COUNT(Assets_in_Billion), MAX(Profits_in_Billion), Sales_in_Billion, COUNT(Headquarters) FROM company WHERE Industry <> "Oil and gas" AND "Profits_in_Billion" > 25.1 OR "Market_Value_in_Billion" >= 79.5 AND "Company_ID" > 10.0 OR "Assets_in_Billion" != 209.5 AND Headquarters <> "USA" AND "Sales_in_Billion" > 433.5 AND Name <> "Walmart" GROUP BY Sales_in_Billion HAVING COUNT(Assets_in_Billion) <> 1 AND COUNT(Headquarters) <= 1


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 1 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT payment_method_code, MIN(amount_payment), MIN(datetime_payment), MAX(customer_id) FROM Customer_Payments WHERE payment_method_code <> "Direct Debit" AND "customer_id" = 10 OR "amount_payment" >= 6970.98 UNION SELECT payment_method_code, MIN(amount_payment), MIN(datetime_payment), MAX(customer_id) FROM Customer_Payments WHERE payment_method_code <> "Direct Debit" AND datetime_payment = "2018-03-12 13:31:36"


Question: SELECT MAX(lesson_id) FROM Lessons WHERE "staff_id" <> 11 AND "price" >= 456.0 AND "lesson_id" < 12 OR "customer_id" <> 8 UNION ALL SELECT MAX(lesson_id) FROM Lessons WHERE "vehicle_id" < 1 AND "customer_id" <= 2 OR lesson_status_code <> "Cancelled"


Question: SELECT SUM(feature_type_code) FROM Other_Available_Features WHERE feature_type_code != "Amenity" OR feature_name != "BurglarAlarm" OR feature_description != "Air Conditioning." AND "feature_id" > 3 INTERSECT SELECT SUM(feature_type_code) FROM Ref_Feature_Types WHERE feature_type_name != "Securiyt, eg Burglar Alarm." OR feature_type_code != "Amenity"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 11 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT document_id FROM Document_Drafts WHERE draft_details <> "x" UNION ALL SELECT document_id FROM Documents WHERE receipt_date <> "1996-05-31 06:51:58"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 11 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT MAX(first_name), AVG(last_name), AVG(date_of_birth) FROM Customers WHERE phone_number <> "(297)122-0086" AND date_became_customer != "2016-04-08 00:28:15" OR last_name != "Leuschke" OR "customer_id" >= 2 AND "amount_outstanding" <= 1000.0 OR cell_mobile_phone_number <> "577-584-4864" OR first_name = "Millie" OR customer_status_code = "Bad Customer" AND email_address = "ehowell@example.com" UNION SELECT MAX(first_name), AVG(last_name), AVG(date_of_birth) FROM Staff WHERE date_left_staff != "2018-02-28 08:26:10" AND middle_name = "Dejon" OR last_name = "Jast" AND "staff_id" <> 13 OR "staff_address_id" <> 1 AND date_joined_staff = "2017-08-30 15:08:37" OR first_name != "Janessa" AND nickname = "weissnat.vincenzo" OR date_of_birth <> "2007-06-11 20:03:28"


Question: SELECT id FROM airport WHERE IATA != "ANC" OR Country <> "Norway" OR City != "Anchorage" OR ICAO <> "ENBR" INTERSECT SELECT id FROM flight WHERE Pilot != "Peterson" OR "id" != 12 OR Vehicle_Flight_number <> "M2-F1 #71" OR Date <> "March 30, 1964" OR "airport_id" != 9 OR "Altitude" >= 3650.0 OR "company_id" > 6


Question: SELECT state FROM AREA_CODE_STATE WHERE state != "CT" OR "area_code" <= 217 UNION ALL SELECT state FROM VOTES WHERE state = "NY" OR "contestant_number" < 3 AND "vote_id" <= 5 AND "phone_number" < 6209222712


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 3


Question: SELECT role_code FROM Employees WHERE "employee_id" <> 5 OR role_code = "PT" OR employee_name != "Clemens" OR other_details != "u" INTERSECT SELECT role_code FROM Roles WHERE role_description <> "Manager"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT staff_id FROM Lessons WHERE "staff_id" <= 12 OR "vehicle_id" <> 1 OR "price" > 306.0 OR lesson_time != "5" UNION ALL SELECT staff_id FROM Staff WHERE "staff_id" = 12 OR date_joined_staff <> "2016-06-05 22:22:23" OR nickname = "lsenger" OR date_of_birth <> "2003-01-16 06:29:11" AND date_left_staff = "2018-03-08 04:23:14" OR middle_name = "Maiya" OR last_name <> "Turner" AND "staff_address_id" > 13


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 1


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2


Question: SELECT document_id FROM Circulation_History WHERE "document_id" = 20 OR "copy_number" < 5 AND "employee_id" != 8 AND "draft_number" > 17 UNION SELECT document_id FROM Documents WHERE "document_id" = 12 AND other_details <> "m" AND shipping_agent_code != "FE" AND document_type_code <> "Hard Drive" OR document_status_code != "working"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1


Question: SELECT customer_id FROM Customers WHERE "customer_address_id" = 1 AND "customer_id" != 1 OR customer_status_code != "Bad Customer" AND email_address = "nichole59@example.com" OR cell_mobile_phone_number = "200.830.8723" OR first_name != "Sigrid" UNION SELECT customer_id FROM Lessons WHERE lesson_time != "6" AND lesson_date <> "2018-03-03 15:10:16" OR lesson_status_code != "Completed" OR "price" != 199.0


Question: SELECT phone_number, vote_id FROM VOTES WHERE "phone_number" != 7148407040 AND "vote_id" != 1 UNION SELECT phone_number, vote_id FROM VOTES WHERE "vote_id" >= 5 OR "phone_number" < 5112677315 AND state != "NJ " AND created <> "2018-03-09 19:03:36" AND "contestant_number" = 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5


Question: SELECT MIN(aid) FROM aircraft WHERE "aid" <= 13 NOT IN (SELECT MIN(aid) FROM aircraft WHERE "distance" >= 1504 OR name = "Airbus A319" OR "aid" > 11)


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2


Question: SELECT Club_ID FROM club WHERE "Club_ID" <= 3 OR "Start_year" <> 2000 OR Region = "France" UNION SELECT Club_ID FROM match_result WHERE "Club_ID" <= 5 OR "Rank" < 1 AND "Points" != 139 OR "Small_Silver" >= 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 1 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 6 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT rank, u_id, i_id FROM review WHERE "u_id" >= 2 AND "i_id" > 5 AND "rating" >= 5 INTERSECT SELECT rank, u_id, i_id FROM review WHERE "u_id" > 2 AND "rating" < 5 OR "rank" != 3 AND "a_id" <> 4 OR "i_id" > 1


Question: SELECT vehicle_details FROM Vehicles WHERE "vehicle_id" < 2 INTERSECT SELECT vehicle_details FROM Vehicles WHERE vehicle_details != "Truck"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 10


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 11 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2


Question: SELECT document_id FROM Circulation_History WHERE "draft_number" != 1 AND "employee_id" < 2 OR "document_id" > 2 UNION ALL SELECT document_id FROM Document_Drafts WHERE draft_details != "w" OR "draft_number" < 17


Question: SELECT COUNT(Ranking), COUNT(Name), AVG(Creation), Department_ID, AVG(Budget_in_Billions) FROM department WHERE "Department_ID" = 15 OR Name <> "Interior" OR Creation <> "1889" UNION ALL SELECT COUNT(Ranking), COUNT(Name), AVG(Creation), Department_ID, AVG(Budget_in_Billions) FROM department WHERE "Num_Employees" > 71436.0 AND Name <> "Commerce" OR "Budget_in_Billions" >= 11.1


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT AVG(District_ID) FROM district WHERE "City_Area" < 12.0 AND "City_Population" > 328512.0 AND "District_ID" != 12 AND Headquartered_City != "Jhang City" UNION ALL SELECT AVG(District_ID) FROM store_district WHERE "Store_ID" <> 1 AND "District_ID" = 15


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 9


Question: SELECT Member_ID FROM member WHERE Card_Number = "LCB7" OR "Level" != 4 EXCEPT SELECT Member_ID FROM purchase WHERE "Member_ID" < 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 7 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT MAX(T1.Branch_ID), T2.Card_Number FROM branch as T1 JOIN member as T2 ON T1.Name = T2.Name WHERE City <> "London" AND Address_road = "Oaks Crescent" AND "Branch_ID" >= 2 AND "Level" >= 2 OR Hometown = "Columbia, South Carolina" AND Open_year <> "2013" AND Card_Number <> "RE95"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT MIN(payment_method_code) FROM Customer_Payments WHERE payment_method_code = "Direct Debit" AND datetime_payment <> "2018-02-27 20:08:53" AND "amount_payment" < 4032.33 EXCEPT SELECT MIN(payment_method_code) FROM Customer_Payments WHERE "amount_payment" <> 4610.26 AND "customer_id" <> 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT state_province_county, city, COUNT(address_id), country, MAX(zip_postcode), line_1_number_building FROM Addresses WHERE country <> "USA" OR "address_id" > 1 AND state_province_county = "Louisiana" AND zip_postcode != "75074" EXCEPT SELECT state_province_county, city, COUNT(address_id), country, MAX(zip_postcode), line_1_number_building FROM Addresses WHERE zip_postcode != "08938" OR "address_id" != 4

Louisiana
New Bernieceburgh
1
USA
38197
7089 Mueller Forks


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Club_ID FROM club WHERE "Club_ID" < 3 OR Club_name = "BK Häcken" AND "Start_year" < 2000 INTERSECT SELECT Club_ID FROM coach WHERE Gender != "M"


Question: SELECT Other_Details, Document_ID FROM Documents WHERE Document_Description = "y" OR "Template_ID" != 4 UNION ALL SELECT Other_Details, Document_ID FROM Paragraphs WHERE Other_Details = "None" AND "Document_ID" > 651512 OR "Paragraph_ID" <= 765713812 AND Paragraph_Text = "Fiji"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT MIN(Grade), SUM(School_ID) FROM school WHERE Type = "Private" OR Grade != "4th grade" OR School != "Punahou School" OR "School_ID" = 1 OR Location <> "Honolulu, Hawaii" UNION ALL SELECT MIN(Grade), SUM(School_ID) FROM school WHERE Location <> "Jakarta, Indonesia"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 7 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT District_ID FROM district WHERE "City_Population" != 89380.0 EXCEPT SELECT District_ID FROM store_district WHERE "Store_ID" >= 5


Question: SELECT Employee_ID FROM employee WHERE City != "Bath" OR Name != "Jason Hobson" AND "Employee_ID" <> 3 UNION SELECT Employee_ID FROM evaluation WHERE Year_awarded <> "2015"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 5


Question: SELECT District_ID, Store_ID FROM store_district WHERE "District_ID" > 11 INTERSECT SELECT District_ID, Store_ID FROM store_district WHERE "District_ID" <> 4


Question: SELECT COUNT(document_id) FROM Draft_Copies WHERE "draft_number" <= 8 AND "copy_number" <> 10 EXCEPT SELECT COUNT(document_id) FROM Draft_Copies WHERE "copy_number" < 5


Question: SELECT id FROM albums WHERE "artist_id" < 114 INTERSECT SELECT id FROM genres WHERE name != "Reggae"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 1


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT document_id FROM Circulation_History WHERE "employee_id" = 2 AND "copy_number" < 5 OR "draft_number" < 20 AND "document_id" > 2 INTERSECT SELECT document_id FROM Documents WHERE document_status_code <> "done" AND other_details <> "b" OR shipping_agent_code = "SH" OR receipt_date <> "2005-09-30 00:10:02" AND receipt_number <> "55" AND "document_id" <= 25


Question: SELECT People_ID FROM people WHERE Graduation_College = "California" AND Nationality != "United States" OR "People_ID" <> 4 OR "Age" <> 30 UNION ALL SELECT People_ID FROM people WHERE "People_ID" != 5 AND Graduation_College <> "Northeastern" AND Nationality != "United States" AND Name != "Tim Naegeli"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 3


Question: SELECT Player_ID FROM player WHERE "Player_ID" = 10 AND "Votes" > 8734 OR Gender != "M" AND Player_name != "Judy Wasylycia-Leis" UNION SELECT Player_ID FROM player_coach WHERE "Starting_year" > 2011 OR "Player_ID" > 14 OR "Coach_ID" <= 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT District_ID FROM store_district WHERE "District_ID" != 11 AND "Store_ID" <= 1 UNION SELECT District_ID FROM store_district WHERE "Store_ID" <> 3


Question: SELECT feature_type_code FROM Other_Available_Features WHERE "feature_id" != 2 AND feature_type_code = "Amenity" AND feature_description <> "Air Conditioning." AND feature_name <> "Pool" UNION ALL SELECT feature_type_code FROM Ref_Feature_Types WHERE feature_type_code = "Amenity"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 12 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 3


Question: SELECT other_details, employee_name FROM Employees WHERE employee_name = "Haley" EXCEPT SELECT other_details, employee_name FROM Employees WHERE "employee_id" > 5 AND role_code = "PT"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT MAX(copy_number), document_id, MAX(draft_number) FROM Draft_Copies WHERE "draft_number" >= 12 UNION SELECT MAX(copy_number), document_id, MAX(draft_number) FROM Draft_Copies WHERE "document_id" <> 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 9 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 11 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Book_ID FROM book WHERE Writer != "Timothy Truman" OR "Issues" < 5.0 AND "Book_ID" < 2 AND Title <> "The Black Lamb" INTERSECT SELECT Book_ID FROM publication WHERE "Price" <> 2000000.0 OR Publication_Date <> "June 2006" AND "Publication_ID" <= 5 OR Publisher != "Pearson"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT Maker FROM car_makers WHERE "Id" <> 1 UNION ALL SELECT Maker FROM model_list WHERE "Maker" = 18 OR Model <> "cadillac"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 5 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT feature_name, feature_id FROM Other_Available_Features WHERE feature_description <> "Burglar Alarm" AND "feature_id" <> 2 UNION SELECT feature_name, feature_id FROM Other_Available_Features WHERE "feature_id" != 4 AND feature_type_code != "Amenity" AND feature_description <> "Swimming Pool." AND feature_name <> "AirCon"


Question: SELECT Member_ID FROM member WHERE Card_Number != "RT91" AND "Level" > 6 OR Name = "Trevard Lindley" OR Hometown = "Jacksonville, Florida" UNION ALL SELECT Member_ID FROM purchase WHERE Branch_ID = "2" OR "Total_pounds" <= 232.09


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT AVG(title), id FROM albums WHERE "artist_id" != 272 AND "id" < 178 UNION SELECT AVG(title), id FROM employees WHERE city = "Calgary" AND title <> "IT Staff" AND email <> "margaret@chinookcorp.com" OR country != "Canada" OR postal_code <> "T2P 2T3" AND phone != "+1 (403) 263-4423" AND "id" < 3 OR fax <> "+1 (403) 262-3322" OR last_name != "Callahan" AND address <> "7727B 41 Ave" AND first_name = "Michael" OR "reports_to" = 2.0 OR hire_date <> "2003-05-03 00:00:00" AND state = "AB"


Question: SELECT COUNT(Id) FROM car_makers WHERE Maker != "daimler benz" OR Country = "4" AND FullName = "General Motors" UNION ALL SELECT COUNT(Id) FROM cars_data WHERE "Cylinders" <= 6 AND "Weight" = 1985 AND Horsepower <> "75" AND "Year" < 1982 OR "Id" > 361


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5


Question: SELECT MIN(document_id) FROM Document_Drafts WHERE "draft_number" > 9 OR "document_id" <= 4 EXCEPT SELECT MIN(document_id) FROM Documents_Mailed WHERE mailing_date != "2007-01-01 22:32:11" AND "mailed_to_address_id" <> 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 4 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2


Question: SELECT Name, Market_Value_in_Billion FROM company WHERE "Company_ID" != 18.0 OR Headquarters = "China" OR "Profits_in_Billion" <> 15.7 OR "Market_Value_in_Billion" = 154.8 UNION SELECT Name, Market_Value_in_Billion FROM company WHERE "Market_Value_in_Billion" < 178.7 OR "Profits_in_Billion" >= 14.2 OR Headquarters != "UK" OR Name = "Industrial and Commercial Bank of China" OR "Company_ID" = 16.0


Question: SELECT AVG(employee_id) FROM Circulation_History WHERE "draft_number" < 17 UNION ALL SELECT AVG(employee_id) FROM Employees WHERE employee_name <> "Koby" OR other_details <> "h"


Question: SELECT SUM(Name) FROM department WHERE "Department_ID" = 1 AND "Num_Employees" <> 109832.0 OR "Budget_in_Billions" <> 11.1 OR Creation = "1849" EXCEPT SELECT SUM(Name) FROM department WHERE "Budget_in_Billions" = 44.6 AND "Department_ID" < 7


Question: SELECT Year_awarded, AVG(Bonus) FROM evaluation WHERE Year_awarded <> "2016" UNION SELECT Year_awarded, AVG(Bonus) FROM evaluation WHERE Year_awarded = "2016" AND Employee_ID != "4"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3


Question: SELECT zip_postcode, line_1_number_building, address_id, state_province_county FROM Addresses WHERE line_1_number_building != "4834 Schaefer Light Suite 947" OR city <> "South Eugene" AND state_province_county != "Georgia" OR zip_postcode = "27559" AND "address_id" != 14 UNION SELECT zip_postcode, line_1_number_building, address_id, state_province_county FROM Addresses WHERE country != "USA"


Question: SELECT MIN(Party) FROM election WHERE "District" = 3 UNION SELECT MIN(Party) FROM party WHERE Party <> "Democratic"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 11 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 12 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 3 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 7


Question: SELECT Member_ID FROM member WHERE Card_Number != "SLB51" AND Name = "Matt Lentz" UNION ALL SELECT Member_ID FROM purchase WHERE "Total_pounds" = 232.09


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 12 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 1 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 5


Question: SELECT T1.Max_disk_Loading, T2.ID FROM aircraft as T1 JOIN airport_aircraft as T2 ON T1.Aircraft_ID = T2.Aircraft_ID


Question: SELECT head_ID FROM head WHERE born_state = "Florida" AND "head_ID" = 8 OR "age" < 69.0 OR name != "Dudley Hart" INTERSECT SELECT head_ID FROM management WHERE "department_ID" <> 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 4 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 11 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT ClubID FROM Club WHERE "ClubID" > 1 OR ClubDesc = "Venture capital fund for student business." OR ClubName = "Hopkins Student Enterprises" UNION SELECT ClubID FROM Member_of_club WHERE Position != "Teaching Coordinator"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT u_id FROM review WHERE "a_id" <= 7 AND "i_id" = 1 OR "rating" >= 10 OR "rank" <= 6 UNION ALL SELECT u_id FROM useracct WHERE name != "Roxi" AND "u_id" != 2


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 2


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 4 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Nationality, MAX(People_ID), COUNT(Name), COUNT(Birth_Date), SUM(Height) FROM people WHERE Nationality != "Russia" OR Birth_Date <> "August 8, 1986" AND Name = "Roman Bragin" OR "Height" > 207.0 GROUP BY Nationality HAVING COUNT(Name) <= 1 OR SUM(Height) != 182.0 AND COUNT(Birth_Date) != 1 OR MAX(People_ID) > 2 UNION SELECT Nationality, MAX(People_ID), COUNT(Name), COUNT(Birth_Date), SUM(Height) FROM people WHERE Name = "Maksim Botin" AND Birth_Date <> "January 22, 1987" OR "Height" = 205.0 AND "People_ID" != 3 GROUP BY Nationality HAVING MAX(People_ID) != 7


Question: SELECT draft_details FROM Document_Drafts WHERE "document_id" != 4 AND "draft_number" < 1 INTERSECT SELECT draft_details FROM Document_Drafts WHERE draft_details != "m" AND "document_id" < 12


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 7 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 10


Question: SELECT SUM(Driver_ID) FROM driver WHERE Party = "Dem" AND "Age" = 52 EXCEPT SELECT SUM(Driver_ID) FROM school_bus WHERE If_full_time <> "T" OR "Years_Working" != 3 OR "Driver_ID" <= 10 OR "School_ID" <= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 3 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Location, County FROM School WHERE Location != "Bremen" AND Mascot != "Redskins" AND School_name = "New Prairie 1" AND IHSAA_Football_Class <> "AAA" AND School_id = "3" OR "Enrollment" = 316 AND County <> "50 Marshall" OR IHSAA_Class <> "AAA" INTERSECT SELECT Location, County FROM School WHERE Location != "Bourbon" AND County = "71 St. Joseph" OR "Enrollment" < 852 AND IHSAA_Football_Class != "AAA" AND School_id != "2" AND Mascot = "Falcons"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Aircraft_ID FROM aircraft WHERE Max_Gross_Weight = "1,370 lb (635 kg)" OR Aircraft <> "Mil Mi-26" AND Description != "Tandem rotor helicopter" OR Max_disk_Loading != "2.6 lb/ft² (14 kg/m²)" OR Total_disk_area != "497 ft² (46.2 m²)" INTERSECT SELECT Aircraft_ID FROM airport_aircraft WHERE "Aircraft_ID" != 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 6 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 5 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT document_id FROM Documents WHERE other_details <> "x" OR receipt_number != "61" OR shipping_agent_code <> "FE" UNION SELECT document_id FROM Documents_Mailed WHERE mailing_date != "1982-01-14 05:50:54" AND "document_id" != 4 OR "mailed_to_address_id" > 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 3 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 1


Question: SELECT School_ID FROM school WHERE Grade = "1st-3rd grade" EXCEPT SELECT School_ID FROM school_bus WHERE "Driver_ID" <> 7 AND "Years_Working" != 3


Question: SELECT SUM(contestant_name) FROM CONTESTANTS WHERE contestant_name != "Kelly Clauss" UNION SELECT SUM(contestant_name) FROM CONTESTANTS WHERE "contestant_number" >= 3 OR contestant_name <> "Allie Rogalski"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 5 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT AVG(document_type_code) FROM Documents WHERE document_status_code = "overdue" OR receipt_number != "37" AND shipping_agent_code <> "FE" AND document_type_code <> "Paper" AND other_details = "r" INTERSECT SELECT AVG(document_type_code) FROM Ref_Document_Types WHERE document_type_description != "f" AND document_type_code != "Hard Drive"


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 7 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT Store_ID FROM store WHERE Type != "Village Store" AND Store_Name = "Neguac" OR "Ranking" >= 2 UNION SELECT Store_ID FROM store_district WHERE "District_ID" <> 15


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 7 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 11 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 8 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 4


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 5 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 3


Question: SELECT Club_ID, Club_name, Start_year FROM club WHERE Region = "UK" OR "Start_year" = 2011 AND "Club_ID" >= 2 OR Club_name <> "AIK" UNION SELECT Club_ID, Club_name, Start_year FROM club WHERE Region <> "France"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 3


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 12 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 9 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 10


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 2 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 10


Question: SELECT copy_number FROM Draft_Copies WHERE "document_id" <= 23 OR "draft_number" = 17 UNION SELECT copy_number FROM Draft_Copies WHERE "copy_number" = 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT COUNT(feature_id) FROM Other_Available_Features WHERE feature_type_code <> "Amenity" OR "feature_id" < 3 EXCEPT SELECT COUNT(feature_id) FROM Other_Property_Features WHERE "property_id" != 12 AND property_feature_description != "quo"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 1


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 7


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 3 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT Branch_ID, Register_Year FROM membership_register_branch WHERE Register_Year <> "2017" OR "Member_ID" >= 8 UNION SELECT Branch_ID, Register_Year FROM membership_register_branch WHERE "Member_ID" > 5 OR Branch_ID <> "4"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID >= 3


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT City, Age, Employee_ID, Name FROM employee WHERE City <> "Wasps" AND "Age" <= 23 INTERSECT SELECT City, Age, Employee_ID, Name FROM employee WHERE "Employee_ID" <= 8 OR Name = "Louis Deacon"


Question: SELECT MIN(document_id) FROM Document_Drafts WHERE "draft_number" != 12 UNION SELECT MIN(document_id) FROM Documents WHERE document_status_code != "working" OR receipt_date != "1983-09-26 09:32:56" OR document_type_code <> "Paper" AND receipt_number != "93"


Question: SELECT document_id FROM Circulation_History WHERE "document_id" >= 1 AND "employee_id" >= 8 AND "copy_number" <> 4 AND "draft_number" = 17 UNION ALL SELECT document_id FROM Documents_Mailed WHERE mailing_date != "1977-04-01 17:03:50"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID = 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 2


Question: SELECT contestant_number FROM CONTESTANTS WHERE contestant_name = "Nita Coster" UNION ALL SELECT contestant_number FROM VOTES WHERE "phone_number" = 7148407040 AND state <> "CA"


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 5