Question: SELECT Continent FROM continents WHERE "ContId" <> 2 OR Continent = "australia" INTERSECT SELECT Continent FROM continents WHERE "ContId" != 3 OR Continent != "america"


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 PetID, pet_age, AVG(PetType) FROM Pets WHERE PetType <> "dog" AND "weight" >= 9.3 OR "PetID" >= 2001 EXCEPT SELECT PetID, pet_age, AVG(PetType) FROM Pets WHERE PetType <> "cat" OR "PetID" = 2002 AND "pet_age" >= 1


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 property_type_code FROM Ref_Property_Types WHERE property_type_description != "House, Bungalow, etc." UNION ALL SELECT property_type_code FROM Ref_Property_Types WHERE property_type_code != "House"


Question: SELECT Branch_ID FROM branch WHERE Open_year != "2015" UNION ALL SELECT Branch_ID FROM membership_register_branch WHERE "Member_ID" <= 8 AND Branch_ID <> "6" OR Register_Year != "2016"


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 <> 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT Name, Level, Card_Number, Member_ID, Hometown FROM member WHERE "Member_ID" != 9 OR Card_Number <> "RCB32" AND "Level" <= 4 OR Hometown <> "Red Jacket, West Virginia" OR Name = "Johnny Williams" UNION ALL SELECT Name, Level, Card_Number, Member_ID, Hometown FROM member WHERE "Member_ID" <> 8 AND Name = "Myron Pryor" OR "Level" <= 6


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 != 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 = 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 <> 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 <= 9


Question: SELECT Major, StuID, Advisor, Age, LName, Sex, city_code, Fname FROM Student WHERE city_code != "PHL" OR Sex = "M" OR "StuID" >= 1005 AND Fname <> "Shiela" OR "Age" <= 22 AND "Advisor" != 8722 AND LName <> "Lee" UNION ALL SELECT Major, StuID, Advisor, Age, LName, Sex, city_code, Fname FROM Student WHERE "Advisor" <= 1148 AND LName != "Kim" OR "Age" > 17 AND "Major" = 600 AND Fname != "Eric" OR "StuID" < 1027 AND Sex = "M"

Major StuID Advisor Age LName Sex city_code Fname


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 < 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 <= 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 >= 3


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 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 <= 3


Question: SELECT property_type_code, date_on_market, oth_feature_1, other_property_details, vendor_requested_price, date_sold, apt_feature_1, hse_feature_1, shp_feature_2, shp_feature_1, buyer_offered_price, property_address, apt_feature_2, property_name, fld_feature_3, apt_feature_3, hse_feature_2, oth_feature_2, room_count, oth_feature_3, shp_feature_3, fld_feature_2, fld_feature_1, property_id, agreed_selling_price, hse_feature_3 FROM Properties WHERE shp_feature_3 <> "None" AND property_type_code = "Apartment" AND hse_feature_1 = "None" OR "vendor_requested_price" > 192374065.8 OR date_sold <> "2012-08-19 07:36:57" AND property_address <> "084 Lakin Vista Apt. 394 Fishertown, MA 16876" AND apt_feature_2 = "est" OR fld_feature_1 != "None" AND shp_feature_1 = "None" AND oth_feature_1 = "None" OR shp_feature_2 != "None" AND other_property_details <> "None" OR fld_feature_3 != "None" OR hse_feature_2 <> "None" OR "room_count" < 9 OR apt_feature_1 = "sed" OR property_name != "the cole" AND oth_feature_2 <> "None" OR oth_feature_3 <> "None" OR hse_feature_3 = "None" OR fld_feature_2 <> "None" OR date_on_market = "2016-05-24 09:57:45" UNION SELECT property_type_code, date_on_market, oth_feature_1, other_property_details, vendor_requested_price, date_sold, apt_feature_1, hse_feature_1, shp_feature_2, shp_feature_1, buyer_offered_price, property_address, apt_feature_2, property_name, fld_feature_3, apt_feature_3, hse_feature_2, oth_feature_2, room_count, oth_feature_3, shp_feature_3, fld_feature_2, fld_feature_1, property_id, agreed_selling_price, hse_feature_3 FROM Properties WHERE shp_feature_2 = "None" OR oth_feature_2 <> "None" AND oth_feature_3 = "None" OR date_sold <> "1997-01-07 19:52:45" AND apt_feature_2 = "aut" AND hse_feature_3 = "None" AND shp_feature_3 = "None" OR "vendor_requested_price" < 13.4715 OR property_name != "wall street" OR apt_feature_1 <> "et" AND "room_count" < 1 AND shp_feature_1 <> "None" AND fld_feature_2 != "None" OR other_property_details <> "None" AND "agreed_selling_price" <> 170766.472 AND property_address != "2088 Bashirian Fork Suite 337 Faustinoport, MT 16771-9320" AND apt_feature_3 != "None" OR hse_feature_2 != "None"

24365 Ulices Run
Homenicktown, MD 88485-6198

107 Roob Courts
Erdmanburgh, IA 42926-0873

986 Hagenes Drives
Draketon, UT 83411-3393

084 Lakin Vista Apt. 394
Fishertown, MA 16876

2765 Schulist Stream
Lindmouth, UT 03391-3817

743 Ephraim Greens
Anniemouth, HI 47084-3853

49578 Ayden Mountains
New Russellhaven, UT 46626

098 Tremaine Highway Suite 569
South Wilford, NJ 46587-3537

4745 Emerson Stravenue Suite 829
South Garret, IN 16772-5682

2088 Bashirian Fork Suite 337
Faustinoport, MT 16771-9320

062 Micaela Court Apt. 707
Margretville, WV 51628-3617

1474 Dibbert Fields Suite 055
South Renee, IN 58286-3097

60845 Else Highway Apt. 826
South Dougfort, CO 43200-4258

6837 Darien Views Apt. 475
South Maraview, KS 77770

092 Paucek Highway Apt. 772
East Erika, IA 61358


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 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 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 <> 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 IATA, name, Country, ICAO, id, City FROM airport WHERE name = "Bergen Airport" UNION SELECT IATA, name, Country, ICAO, id, City FROM airport WHERE ICAO != "EHAM" OR name = "Akureyri Airport" AND Country = "Netherlands" OR "id" > 8 OR City = "Baltimore" AND IATA = "BGO"

AEY
Akureyri Airport
Iceland
BIAR
1
Akureyri

ANC
Ted Stevens Airport
United States
PANC
3
Anchorage

BCN
El Prat Airport
Spain
LEBL
5
Barcelona

BLL
Billund Airport
Denmark
EKBI
7
Billund

BOS
Logan International Airport
United States
KBOS
8
Boston

BRU
National Airport
Belgium
EBBR
9
Brussels

BWI
Baltimore-Washington Airport
United States
KBWI
4
Baltimore


Question: SELECT customer_id, payment_method_code FROM Customer_Payments WHERE "customer_id" <= 2 AND "amount_payment" != 5475.26 UNION ALL SELECT customer_id, payment_method_code FROM Customer_Payments WHERE "customer_id" < 2 AND datetime_payment != "2018-02-05 18:44:46" OR payment_method_code = "Direct Debit" OR "amount_payment" = 9414.74


Question: SELECT id FROM albums WHERE "artist_id" > 91 EXCEPT SELECT id FROM playlists WHERE "id" < 14 OR name <> "Music"


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 <> 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 != 8 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 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT AVG(Final_Table_Made), SUM(Money_Rank), Poker_Player_ID, SUM(Earnings) FROM poker_player WHERE "Final_Table_Made" >= 42.0 AND "Poker_Player_ID" = 5 OR "Money_Rank" != 58.0 OR "Earnings" >= 142800.0 AND "People_ID" = 1 AND "Best_Finish" < 3.0 UNION SELECT AVG(Final_Table_Made), SUM(Money_Rank), Poker_Player_ID, SUM(Earnings) FROM poker_player WHERE "Earnings" > 142800.0 AND "Money_Rank" > 166.0


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 = 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT customer_id FROM Customer_Payments WHERE payment_method_code != "Direct Debit" AND datetime_payment = "2018-02-27 20:08:53" UNION SELECT customer_id FROM Customers WHERE date_of_birth <> "1995-07-17 12:13:16" OR phone_number != "+14(5)2351480248" AND "amount_outstanding" <> 8144.0 OR cell_mobile_phone_number <> "081-097-3684" OR customer_status_code != "Bad Customer"


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 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 != 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT IHSAA_Football_Class, Enrollment FROM School WHERE IHSAA_Football_Class <> "AAA" AND Location != "Bourbon" OR School_id <> "5" AND IHSAA_Class != "AAA" AND School_name <> "Culver Community" AND County <> "50 Marshall" EXCEPT SELECT IHSAA_Football_Class, Enrollment FROM School WHERE IHSAA_Class != "AAA" AND Location <> "Bourbon" OR School_id = "1" AND "Enrollment" != 316


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 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 > 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 >= 3


Question: SELECT MAX(feature_description) FROM Other_Available_Features WHERE feature_description <> "Air Conditioning." OR feature_type_code <> "Security" UNION ALL SELECT MAX(feature_description) FROM Other_Available_Features WHERE feature_name <> "BurglarAlarm" AND "feature_id" <> 3 OR feature_type_code = "Amenity"


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 contestant_name FROM CONTESTANTS WHERE "contestant_number" <= 11 INTERSECT SELECT contestant_name FROM CONTESTANTS WHERE "contestant_number" >= 11


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 document_id FROM Documents_Mailed WHERE "mailed_to_address_id" > 3 OR mailing_date = "2007-01-01 22:32:11" OR "document_id" != 12 EXCEPT SELECT document_id FROM Draft_Copies WHERE "draft_number" = 20 AND "document_id" < 1


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


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 != 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 = 2


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 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 SUM(Big_Silver) FROM match_result WHERE "Bronze" = 6 OR "Small_Silver" > 10 AND "Gold" <> 20 AND "Points" <> 168 AND "Big_Silver" = 14 OR "Club_ID" >= 6 UNION ALL SELECT SUM(Big_Silver) FROM match_result WHERE "Gold" = 7 AND "Bronze" < 9 AND "Points" <> 66 AND "Small_Silver" < 16


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 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 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 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 document_id FROM Documents WHERE receipt_number = "69" OR other_details != "u" OR document_type_code <> "Paper" OR document_status_code = "done" OR "document_id" >= 7 OR receipt_date = "1999-04-17 14:19:32" UNION ALL SELECT document_id FROM Documents_Mailed WHERE "document_id" < 12 OR mailing_date = "1973-02-21 10:17:01" AND "mailed_to_address_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 <> 7


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 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 = 6 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Election_ID, Delegate FROM election WHERE "First_Elected" = 2003.0 OR "Election_ID" <= 8 AND "District" >= 2 UNION SELECT Election_ID, Delegate FROM election WHERE "Election_ID" = 7 OR Counties_Represented != "12.1 12A" OR Delegate != "Bates, Gail H. Gail H. Bates" AND Committee != "Environmental Matters (Vice-Chair)" OR "Party" != 7 OR "First_Elected" <= 2003.0

DeBoy, Steven J. Sr. Steven J. DeBoy, Sr.

Malone, James E. Jr. James E. Malone, Jr.


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 SUM(ClubID) FROM Club WHERE ClubLocation = "HHH" EXCEPT SELECT SUM(ClubID) FROM Member_of_club WHERE "StuID" < 1001 AND 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 <= 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 document_type_code FROM Documents WHERE document_status_code <> "overdue" AND shipping_agent_code = "US" OR "document_id" >= 13 AND receipt_number != "93" AND receipt_date = "1976-09-15 19:24:17" AND other_details <> "n" EXCEPT SELECT document_type_code FROM Ref_Document_Types WHERE document_type_description = "b" AND document_type_code != "Paper"


Question: SELECT Employee_ID FROM evaluation WHERE "Bonus" < 3200.0 OR Year_awarded != "2015" EXCEPT SELECT Employee_ID FROM evaluation WHERE "Bonus" >= 3200.0 OR Year_awarded = "2017" OR Employee_ID <> "1"


Question: SELECT draft_details, document_id, draft_number FROM Document_Drafts WHERE "draft_number" <> 0 OR "document_id" != 2 UNION SELECT draft_details, document_id, draft_number FROM Document_Drafts WHERE "draft_number" < 14 OR draft_details = "m" AND "document_id" >= 17


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 < 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 > 3


Question: SELECT SUM(AllergyType) FROM Allergy_Type WHERE AllergyType <> "animal" OR Allergy != "Ragweed" UNION ALL SELECT SUM(AllergyType) FROM Allergy_Type WHERE Allergy <> "Grass Pollen" AND AllergyType <> "animal"


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 target_u_id, trust FROM trust WHERE "source_u_id" > 1 OR "trust" != 10 AND "target_u_id" >= 3 UNION SELECT target_u_id, trust FROM trust WHERE "target_u_id" < 3 OR "source_u_id" > 1 AND "trust" < 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 <> 4


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 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 <= 1 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 > 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 < 9 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT School_id FROM School WHERE IHSAA_Class = "AAA" AND County <> "50 Marshall" OR Mascot <> "Jimmies" AND IHSAA_Football_Class = "AAAA" UNION SELECT School_id FROM budget WHERE "School_id" = 2 OR "Invested" <> 8335 AND "total_budget_percent_budgeted" != 2.0 OR "Budgeted" <= 4979 AND "Year" < 2001 OR Budget_invested_percent = "42.9" OR "total_budget_percent_invested" <> 2.0


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 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 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 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 <> 1 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 >= 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 <> 9 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 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 <> 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 <= 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 <> 5 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 <= 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 < 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 >= 5 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 3


Question: SELECT aid, name, distance FROM aircraft WHERE name = "Schwitzer 2-33" OR "distance" < 4103 INTERSECT SELECT aid, name, distance FROM aircraft WHERE name != "Piper Archer III" OR "aid" <= 10


Question: SELECT head_ID, born_state, name, age FROM head WHERE born_state <> "California" OR "head_ID" >= 3 INTERSECT SELECT head_ID, born_state, name, age FROM head WHERE "head_ID" = 5 OR born_state != "Connecticut"


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 != 7


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 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 >= 9


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 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 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 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 > 10


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 <= 6 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 <> 1 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 = 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 = 11 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 <= 3


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 != 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 4


Question: SELECT Name, Creation, Department_ID, Budget_in_Billions, Num_Employees FROM department WHERE Creation != "1903" AND Name != "Commerce" OR "Ranking" <= 4 EXCEPT SELECT Name, Creation, Department_ID, Budget_in_Billions, Num_Employees FROM department WHERE "Num_Employees" >= 208000.0 OR Name = "Energy" OR "Budget_in_Billions" <> 10.7 OR Creation = "1953" OR "Ranking" >= 9 AND "Department_ID" < 15


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 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 Employee_ID FROM evaluation WHERE Employee_ID != "2" AND "Bonus" = 3200.0 EXCEPT SELECT Employee_ID FROM hiring WHERE "Employee_ID" > 6


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 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 <> 3 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 < 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


Question: SELECT flno FROM flight WHERE destination <> "Honolulu" AND "flno" < 13 AND "aid" > 10 AND "distance" != 1749 OR departure_date = "04/12/2005 09:15" EXCEPT SELECT flno FROM flight WHERE "flno" <> 33


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 <= 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 <= 3


Question: SELECT COUNT(Name) FROM company WHERE "Profits_in_Billion" > 11.1 OR "Assets_in_Billion" > 2265.8 AND "Company_ID" < 5.0 AND Industry <> "Oil and gas" OR "Market_Value_in_Billion" <= 170.1 AND "Sales_in_Billion" <> 62.4 AND Name = "Berkshire Hathaway" OR Headquarters != "Brazil" UNION ALL SELECT COUNT(Name) FROM people WHERE Graduation_College <> "Virginia" OR Nationality = "United Kindom" AND "Age" <> 31


Question: SELECT customer_status_code, amount_outstanding, date_became_customer FROM Customers WHERE first_name <> "Leif" AND date_became_customer != "2016-11-30 10:37:41" AND cell_mobile_phone_number = "739-333-6966x187" AND "amount_outstanding" <= 9443.0 OR "customer_address_id" >= 9 AND "customer_id" >= 3 OR date_of_birth = "1988-09-19 14:45:56" OR last_name != "Kohler" OR customer_status_code = "Good Customer" AND email_address != "everette.goyette@example.org" AND phone_number <> "(662)490-3108" EXCEPT SELECT customer_status_code, amount_outstanding, date_became_customer FROM Customers WHERE "customer_address_id" > 1 AND phone_number = "1-618-535-9750" OR cell_mobile_phone_number <> "(780)719-4206x033" OR date_of_birth <> "1996-05-23 01:21:54" AND "amount_outstanding" >= 5494.0


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 != 2


Question: SELECT Location, Grade, Type, School FROM school WHERE Location = "Jakarta, Indonesia" AND Type != "Private Catholic" AND School != "Punahou School" UNION SELECT Location, Grade, Type, School FROM school WHERE School = "Noelani Elementary School" OR Grade != "4th grade" AND Type != "Public" OR "School_ID" != 7 AND Location != "Los Angeles, California"

Cambridge, Massachusetts
College
Private
Harvard Law School

Honolulu, Hawaii
5th-12th grade
Private
Punahou School

Honolulu, Hawaii
Kindergarten
Public
Noelani Elementary School

Jakarta, Indonesia
1st-3rd grade
Private Catholic
St. Francis Assisi

Jakarta, Indonesia
4th grade
Public
State Elementary School Menteng 01

Los Angeles, California
Freshman–Sophomore year
Private
Occidental College

New York City
Junior–Senior year
Private
Columbia University


Question: SELECT Country, COUNT(City), COUNT(ICAO), COUNT(name), COUNT(IATA), MAX(id) FROM airport WHERE Country != "Denmark" OR name != "Billund Airport" OR IATA <> "AMS" AND City = "Billund" OR "id" >= 2 OR ICAO != "EKBI" GROUP BY Country HAVING COUNT(City) > 1 OR COUNT(IATA) <> 1 OR MAX(id) < 5 EXCEPT SELECT Country, COUNT(City), COUNT(ICAO), COUNT(name), COUNT(IATA), MAX(id) FROM airport WHERE "id" != 6 OR name <> "Baltimore-Washington Airport" AND City = "Anchorage" GROUP BY Country HAVING COUNT(ICAO) < 1 OR MAX(id) > 7 AND COUNT(name) < 1 AND COUNT(City) <= 3

Country COUNT(City) COUNT(ICAO) COUNT(name) COUNT(IATA) MAX(id)


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 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 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 > 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 >= 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 <> 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 2


Question: SELECT temporary_acting FROM management WHERE "department_ID" >= 15 OR "head_ID" < 5 AND temporary_acting != "Yes" INTERSECT SELECT temporary_acting FROM management WHERE "head_ID" <> 4 OR "department_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 <= 3


Question: SELECT AVG(property_type_code) FROM Properties WHERE property_type_code != "Other" INTERSECT SELECT AVG(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 <> 7 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 = 2


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 >= 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 = 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 > 7


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 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 Employee_ID, AVG(Bonus) FROM evaluation WHERE Year_awarded = "2011" AND Employee_ID != "2" OR "Bonus" <> 3200.0 UNION ALL SELECT Employee_ID, AVG(Bonus) FROM evaluation WHERE "Bonus" <= 3200.0


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 Register_Year, AVG(Branch_ID), Member_ID FROM membership_register_branch WHERE Register_Year <> "2016" OR "Member_ID" >= 8 OR Branch_ID <> "1" UNION ALL SELECT Register_Year, AVG(Branch_ID), Member_ID FROM membership_register_branch WHERE Branch_ID <> "1" AND "Member_ID" > 5


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 Member_ID FROM member WHERE Name != "Johnny Williams" AND "Member_ID" != 4 INTERSECT SELECT Member_ID FROM purchase WHERE Year <> "2018"


Question: SELECT other_details FROM Documents WHERE shipping_agent_code <> "UP" UNION SELECT other_details FROM Employees WHERE other_details != "b" OR "employee_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 != 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 >= 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 >= 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 = 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT Member_ID FROM member WHERE Card_Number != "RT91" OR "Level" = 6 OR Hometown <> "Columbia, South Carolina" OR Name != "Trevard Lindley" AND "Member_ID" <> 7 EXCEPT SELECT Member_ID FROM membership_register_branch WHERE Branch_ID != "1"


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 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 ClubID FROM Club WHERE ClubName <> "Tennis Club" OR "ClubID" <> 2 OR ClubDesc = "Refurbish computers; teach kids and adults about computer basics." AND ClubLocation != "AKW" UNION SELECT ClubID FROM Member_of_club WHERE "StuID" = 1007 OR "ClubID" != 2 OR Position != "CTO"


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 != 4


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 != 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 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT u_id FROM review WHERE "a_id" <= 1 OR "rank" > 7 UNION SELECT u_id FROM useracct WHERE name <> "Mark"


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 != 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT MIN(feature_name) FROM Other_Available_Features WHERE feature_description <> "Air Conditioning." INTERSECT SELECT MIN(feature_name) FROM Other_Available_Features WHERE feature_description = "Burglar Alarm"


Question: SELECT FullName, Id, Maker, Country FROM car_makers WHERE Country <> "6" AND FullName != "Volvo" OR "Id" != 2 UNION ALL SELECT FullName, Id, Maker, Country FROM car_makers WHERE Maker != "ford"


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


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 > 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 != 7


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 >= 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 <= 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 < 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 Store_ID FROM store WHERE Type <> "Village Store" OR "Area_size" < 26.69 OR Store_Name = "Neguac" AND "Store_ID" <> 3 EXCEPT SELECT Store_ID FROM store_product WHERE "Store_ID" <= 1


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 document_id FROM Document_Drafts WHERE "draft_number" = 4 AND draft_details <> "l" EXCEPT SELECT document_id FROM Documents_Mailed WHERE "mailed_to_address_id" <= 0


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 SUM(customer_address_id), phone_number FROM Customers WHERE "customer_id" > 1 OR customer_status_code != "Bad Customer" AND last_name = "Tromp" OR email_address != "afranecki@example.com" AND date_of_birth = "1993-03-08 08:48:42" OR phone_number = "206-054-0689x05861" AND cell_mobile_phone_number = "848-099-2095x785" OR first_name != "Carole" AND "customer_address_id" = 8 OR "amount_outstanding" > 9443.0 EXCEPT SELECT SUM(customer_address_id), phone_number FROM Customers WHERE "customer_address_id" <= 9 AND email_address = "kitty.hand@example.net" OR "amount_outstanding" < 7256.0 AND "customer_id" >= 12 OR first_name != "Dianna" OR phone_number <> "1-387-884-0656" OR customer_status_code = "Bad Customer" OR date_of_birth <> "1991-12-05 02:50:15" AND date_became_customer != "2017-04-16 05:12:21" OR last_name = "Spinka" OR cell_mobile_phone_number = "+57(9)4602098297"


Question: SELECT role_code, other_details, employee_name, employee_id FROM Employees WHERE employee_name != "Jordyn" OR "employee_id" > 1 AND other_details = "f" UNION ALL SELECT role_code, other_details, employee_name, employee_id FROM Employees WHERE "employee_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 < 10


Question: SELECT document_id, mailing_date, mailed_to_address_id FROM Documents_Mailed WHERE mailing_date != "1993-05-24 22:13:48" AND "mailed_to_address_id" > 7 OR "document_id" > 12 UNION ALL SELECT document_id, mailing_date, mailed_to_address_id FROM Documents_Mailed WHERE "mailed_to_address_id" > 3


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 > 4 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT id FROM albums WHERE "id" < 104 OR "artist_id" < 50 AND title = "Beethoven: Symphony No. 6 'Pastoral' Etc." UNION ALL SELECT id FROM genres WHERE name <> "Sci Fi & Fantasy" OR "id" >= 7


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 < 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 3


Question: SELECT Driver_ID FROM driver WHERE Name <> "Tim Larson" OR Party <> "Dem" AND "Age" < 45 OR "Driver_ID" <> 1 AND Home_city != "East Hartford" UNION ALL SELECT Driver_ID FROM school_bus WHERE "School_ID" != 5 OR "Years_Working" <= 6 AND If_full_time != "F" AND "Driver_ID" = 7


Question: SELECT Fname, Age, Sex FROM Student WHERE LName != "Jones" OR "Advisor" = 1148 AND Sex != "M" OR "Age" <> 18 OR "Major" <= 520 OR Fname <> "Paul" UNION ALL SELECT Fname, Age, Sex FROM Student WHERE LName != "Kumar" OR "StuID" > 1026 OR "Advisor" >= 2192 OR Fname != "Michael" AND city_code = "PHL" OR Sex = "M"


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 < 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT MAX(T1.Issues), T2.Publisher FROM book as T1 JOIN publication as T2 ON T1.Book_ID = T2.Book_ID WHERE Publisher <> "Pearson" GROUP BY Issues HAVING Publisher <> "Bertelsmann" OR Price <= 2000000.0


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 shipping_agent_description, shipping_agent_code, shipping_agent_name FROM Ref_Shipping_Agents WHERE shipping_agent_name != "Fedex" OR shipping_agent_description != "t" AND shipping_agent_code = "SH" UNION SELECT shipping_agent_description, shipping_agent_code, shipping_agent_name FROM Ref_Shipping_Agents WHERE shipping_agent_code = "SH" AND shipping_agent_description <> "g"


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 <> 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 Template_ID FROM Documents WHERE Document_Name <> "Customer reviews" AND "Template_ID" > 20 UNION ALL SELECT Template_ID FROM Templates WHERE "Template_ID" != 22 AND Template_Type_Code <> "BK" AND Date_Effective_To <> "2001-04-18 09:29:52" AND Date_Effective_From <> "1975-10-20 02:28:58"


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 COUNT(Industry), Profits_in_Billion, MAX(Market_Value_in_Billion) FROM company WHERE "Profits_in_Billion" <= 14.4 OR Name != "BP" OR Headquarters != "USA" GROUP BY Profits_in_Billion HAVING COUNT(Industry) = 1 INTERSECT SELECT COUNT(Industry), Profits_in_Billion, MAX(Market_Value_in_Billion) FROM company WHERE Industry != "Oil and gas" AND Headquarters <> "Netherlands" AND "Sales_in_Billion" = 147.3 OR "Market_Value_in_Billion" != 180.0 OR "Company_ID" <= 15.0 AND "Assets_in_Billion" < 209.5 GROUP BY Profits_in_Billion HAVING MAX(Market_Value_in_Billion) >= 147.4 AND COUNT(Industry) <= 1


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 feature_name, feature_type_code FROM Other_Available_Features WHERE "feature_id" != 3 EXCEPT SELECT feature_name, feature_type_code FROM Other_Available_Features WHERE feature_description <> "Burglar Alarm"


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 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 address_details, SUM(address_id) FROM Addresses GROUP BY address_details HAVING SUM(address_id) = 2 INTERSECT SELECT address_details, SUM(address_id) FROM Addresses GROUP BY address_details HAVING SUM(address_id) <= 2


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 > 9


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 != 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 5


Question: SELECT SUM(customer_id), MAX(amount_payment), MAX(datetime_payment), payment_method_code FROM Customer_Payments WHERE datetime_payment != "2018-02-06 13:35:58" AND "customer_id" <> 2 AND "amount_payment" < 4773.16 EXCEPT SELECT SUM(customer_id), MAX(amount_payment), MAX(datetime_payment), payment_method_code FROM Customer_Payments WHERE "amount_payment" = 4032.33 AND "customer_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 <= 1 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 <> 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 > 7


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 <= 4


Question: SELECT Template_Details, Template_ID, MIN(Version_Number) FROM Templates WHERE Date_Effective_To = "1976-10-28 10:08:50" AND Template_Details = "" AND Template_Type_Code = "PPT" EXCEPT SELECT Template_Details, Template_ID, MIN(Version_Number) FROM Templates WHERE "Version_Number" <> 6 AND Template_Details <> "" OR Template_Type_Code <> "PP"


Question: SELECT Member_ID FROM member WHERE Card_Number <> "RE95" AND "Level" <= 6 OR Hometown = "Red Jacket, West Virginia" EXCEPT SELECT Member_ID FROM membership_register_branch WHERE "Member_ID" >= 3 AND Register_Year = "2016" OR Branch_ID = "4"


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 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 != 5


Question: SELECT trust FROM trust WHERE "source_u_id" <= 1 UNION ALL SELECT trust FROM trust WHERE "source_u_id" < 1 OR "target_u_id" = 5 AND "trust" <= 7


Question: SELECT People_ID, COUNT(Name), COUNT(Nationality), MAX(Height) FROM people WHERE Birth_Date <> "August 8, 1986" GROUP BY People_ID HAVING MAX(Height) > 187.0 EXCEPT SELECT People_ID, COUNT(Name), COUNT(Nationality), MAX(Height) FROM people WHERE Name != "Sergey Grankin" OR Nationality <> "Russia" OR "People_ID" != 6 AND Birth_Date != "January 22, 1987" AND "Height" < 187.0 GROUP BY People_ID HAVING COUNT(Name) <= 1

People_ID COUNT(Name) COUNT(Nationality) MAX(Height)


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 shipping_agent_code FROM Documents WHERE other_details = "m" AND receipt_date != "1973-11-05 21:48:53" OR receipt_number != "79" AND document_status_code <> "overdue" UNION ALL SELECT shipping_agent_code FROM Ref_Shipping_Agents WHERE shipping_agent_code != "AL" OR shipping_agent_name <> "UPS" OR shipping_agent_description != "t"


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 > 8 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 != 7 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 7


Question: SELECT SUM(last_name), MIN(customer_id), MIN(date_became_customer), first_name, customer_address_id, COUNT(customer_status_code), AVG(phone_number), SUM(date_of_birth) FROM Customers WHERE first_name = "Amya" OR last_name <> "Koelpin" UNION SELECT SUM(last_name), MIN(customer_id), MIN(date_became_customer), first_name, customer_address_id, COUNT(customer_status_code), AVG(phone_number), SUM(date_of_birth) FROM Customers WHERE "amount_outstanding" != 9500.0 AND first_name <> "Ray"


Question: SELECT People_ID FROM employment WHERE "Year_working" <= 2 AND "Company_ID" <= 17 AND "People_ID" >= 2 UNION SELECT People_ID FROM people WHERE Graduation_College <> "Wisconsin–Stevens Point" AND "People_ID" = 1 AND Nationality != "United States" AND Name != "David Butler"


Question: SELECT state FROM AREA_CODE_STATE WHERE "area_code" > 740 AND state != "MN" INTERSECT SELECT state FROM VOTES WHERE "vote_id" <= 2 AND "phone_number" = 7148407040 OR "contestant_number" <> 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 > 10


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 title, i_id FROM item WHERE "i_id" = 4 AND title != "pear" EXCEPT SELECT title, i_id FROM item WHERE "i_id" <> 3 AND title = "blue hoodie"


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 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 != 7


Question: SELECT contestant_number FROM CONTESTANTS WHERE contestant_name != "Jessie Eichman" AND "contestant_number" < 9 EXCEPT SELECT contestant_number FROM VOTES WHERE created <> "2018-03-09 19:03:36" OR "vote_id" <= 5 OR "phone_number" > 6209222712


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 != 8 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 7


Question: SELECT state FROM AREA_CODE_STATE WHERE "area_code" > 623 OR state <> "IN" INTERSECT SELECT state FROM VOTES WHERE "vote_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 < 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 >= 2 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 4


Question: SELECT document_id FROM Documents WHERE receipt_date = "1982-09-27 14:52:15" AND document_status_code != "done" OR receipt_number = "189" AND other_details = "h" OR document_type_code <> "CD" INTERSECT SELECT document_id FROM Documents_Mailed WHERE mailing_date != "1982-01-14 05:50:54" AND "document_id" != 12


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 other_details FROM Documents WHERE "document_id" <> 4 AND other_details != "r" UNION SELECT other_details FROM Employees WHERE role_code = "ED" AND "employee_id" < 8


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 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 AVG(u_id) FROM useracct WHERE "u_id" < 5 UNION SELECT AVG(u_id) FROM useracct WHERE name <> "Rosie"


Question: SELECT Employee_ID FROM employee WHERE "Employee_ID" = 10 OR "Age" > 32 AND City <> "Wasps" OR Name != "George Chuter" EXCEPT SELECT Employee_ID FROM hiring WHERE Start_from <> "2008" OR Is_full_time != "T" AND "Employee_ID" <= 2


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 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 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 document_id, copy_number FROM Circulation_History WHERE "draft_number" != 17 OR "copy_number" >= 5 OR "employee_id" >= 1 OR "document_id" < 10 EXCEPT SELECT document_id, copy_number FROM Draft_Copies WHERE "copy_number" <> 5


Question: SELECT Employee_ID FROM employee WHERE Name <> "Tim Payne" UNION SELECT Employee_ID FROM hiring WHERE Is_full_time <> "T" OR "Shop_ID" > 1


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 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 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 MAX(T1.Club_ID), T2.Gender FROM club as T1 JOIN coach as T2 ON T1.Club_ID = T2.Club_ID WHERE Gender = "M" OR Club_name <> "Gefle IF" AND Coach_name = "James Wong" OR "Start_year" <= 2011 OR Region = "UK" OR "Rank" <= 1 AND "Coach_ID" >= 4


Question: SELECT AVG(T1.ClubID), T2.StuID FROM Club as T1 JOIN Member_of_club as T2 ON T1.ClubID = T2.ClubID WHERE ClubName = "Bootup Baltimore"


Question: SELECT COUNT(Shop_ID) FROM hiring WHERE "Employee_ID" <> 5 AND Is_full_time != "T" EXCEPT SELECT COUNT(Shop_ID) FROM shop WHERE Location != "Jakobstad" OR "Number_products" < 6000 OR District != "Lahden Stadion" AND "Shop_ID" = 3 OR Manager_name <> "Mika Lehkosuo" AND Name <> "IFK Mariehamn"


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 <= 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 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 > 4


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 MIN(document_status_code) FROM Documents WHERE shipping_agent_code = "UP" UNION SELECT MIN(document_status_code) FROM Ref_Document_Status WHERE document_status_description = "mailed late" AND document_status_code = "working"


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 Store_ID FROM store WHERE "Number_of_product_category" < 990.0 UNION ALL SELECT Store_ID FROM store_district WHERE "District_ID" != 15 OR "Store_ID" = 1


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 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 SUM(Major), MIN(city_code), Age FROM Student WHERE "Advisor" = 5718 AND "Age" != 20 EXCEPT SELECT SUM(Major), MIN(city_code), Age FROM Student WHERE Sex != "M" AND Fname != "Eric" OR LName <> "Kim" AND "StuID" = 1015 OR city_code = "PHL" OR "Major" < 600 AND "Age" < 20 OR "Advisor" = 2192


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 SUM(Coach_ID) FROM coach WHERE "Coach_ID" <= 1 OR "Club_ID" > 1 UNION ALL SELECT SUM(Coach_ID) FROM player_coach WHERE "Starting_year" <= 2012


Question: SELECT AVG(aid) FROM certificate WHERE "eid" <= 274878974 UNION ALL SELECT AVG(aid) FROM flight WHERE origin <> "Los Angeles" AND arrival_date <> "04/12/2005 03:18" AND "aid" <> 3 OR "flno" >= 7 AND destination = "Chicago" OR "price" != 202.45 AND departure_date != "04/12/2005 08:32"


Question: SELECT AVG(Employee_ID), COUNT(City), COUNT(Age), Name FROM employee WHERE "Employee_ID" <> 2 AND "Age" != 36 GROUP BY Name HAVING COUNT(City) <> 1 OR AVG(Employee_ID) > 4.0 INTERSECT SELECT AVG(Employee_ID), COUNT(City), COUNT(Age), Name FROM employee WHERE "Employee_ID" > 3 OR "Age" <> 36 AND City <> "Bath" AND Name = "Matt Stevens" GROUP BY Name HAVING AVG(Employee_ID) >= 8.0 AND COUNT(Age) >= 1 OR COUNT(City) < 1

AVG(Employee_ID) COUNT(City) COUNT(Age) Name


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 AVG(Name) FROM company WHERE "Profits_in_Billion" <= 20.1 AND "Market_Value_in_Billion" >= 178.7 AND "Assets_in_Billion" <> 1563.9 OR "Sales_in_Billion" >= 433.5 AND Headquarters != "China" OR "Company_ID" = 15.0 INTERSECT SELECT AVG(Name) FROM people WHERE Graduation_College != "Northeastern" AND "Age" < 37 AND Nationality <> "United Kindom"


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 != 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 7


Question: SELECT COUNT(head_ID), name, age FROM head WHERE "age" < 50.0 AND name = "Pádraig Harrington" AND "head_ID" <= 6 OR born_state = "Connecticut" UNION ALL SELECT COUNT(head_ID), name, age FROM head WHERE "head_ID" > 5 AND name != "Stewart Cink" AND born_state != "California" AND "age" > 53.0


Question: SELECT Best_Finish, Poker_Player_ID, Final_Table_Made, People_ID, Money_Rank FROM poker_player WHERE "Poker_Player_ID" > 4 OR "Best_Finish" >= 3.0 UNION SELECT Best_Finish, Poker_Player_ID, Final_Table_Made, People_ID, Money_Rank FROM poker_player WHERE "Final_Table_Made" != 26.0 AND "Poker_Player_ID" > 2 AND "Best_Finish" >= 3.0 OR "People_ID" <= 2


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 < 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 4


Question: SELECT SUM(Employee_ID) FROM evaluation WHERE Employee_ID != "2" EXCEPT SELECT SUM(Employee_ID) FROM hiring WHERE "Employee_ID" < 6 OR Start_from = "2008" OR Is_full_time = "F" AND "Shop_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 = 3


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 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 <> 4 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 = 2 EXCEPT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2


Question: SELECT Store_ID FROM store WHERE "Ranking" <> 10 OR Store_Name != "Doaktown" UNION SELECT Store_ID FROM store_district WHERE "Store_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 = 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 <> 8 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 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 >= 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 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 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 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 >= 8 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 < 8 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 != 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 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 Shop_ID FROM hiring WHERE Start_from <> "2011" OR Is_full_time = "T" OR "Employee_ID" < 3 UNION SELECT Shop_ID FROM shop WHERE District != "Finnair Stadium" AND Manager_name <> "Job Dragtsma"


Question: SELECT Rank FROM match_result WHERE "Bronze" <> 10 AND "Small_Silver" > 9 OR "Club_ID" = 1 EXCEPT SELECT Rank FROM player WHERE "Votes" >= 5490 AND Occupation != "Design Coordinator" AND Player_name != "Jim Maloway" AND Rank <> "3rd" OR Sponsor_name <> "Winnipeg Centre" OR Gender = "M" OR "Player_ID" > 14


Question: SELECT SUM(Date), MIN(id), SUM(Velocity), Vehicle_Flight_number, SUM(Altitude) FROM flight WHERE "company_id" < 11 AND "Velocity" < 240.0 AND "Altitude" = 3650.0 AND "airport_id" = 2 AND "id" > 8 OR Pilot = "Thompson" AND Vehicle_Flight_number <> "M2-F1 #73" EXCEPT SELECT SUM(Date), MIN(id), SUM(Velocity), Vehicle_Flight_number, SUM(Altitude) FROM flight WHERE "id" > 7 AND Pilot != "Peterson" AND "company_id" < 3 OR "Altitude" > 3650.0 AND Vehicle_Flight_number != "M2-F1 #64"

SUM(Date) MIN(id) SUM(Velocity) Vehicle_Flight_number SUM(Altitude)


Question: SELECT MIN(Store_ID) FROM store WHERE "Store_ID" != 1 OR Type != "City Mall" UNION ALL SELECT MIN(Store_ID) FROM store_district WHERE "District_ID" <> 15


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 != 2


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 <> 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 > 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 <= 4 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 5


Question: SELECT last_name, date_of_birth, staff_id, date_joined_staff FROM Staff WHERE first_name = "Kaitlin" OR middle_name <> "Stephania" OR last_name <> "Turner" OR date_left_staff != "2018-03-04 17:13:53" OR nickname != "nicholaus92" OR date_of_birth = "1995-06-03 08:09:17" UNION ALL SELECT last_name, date_of_birth, staff_id, date_joined_staff FROM Staff WHERE date_of_birth != "2004-05-19 14:11:13" OR first_name <> "Titus" AND "staff_address_id" <= 6


Question: SELECT Shop_ID, Is_full_time, Start_from FROM hiring WHERE "Shop_ID" != 8 OR Is_full_time != "T" OR Start_from = "2012" AND "Employee_ID" >= 6 UNION SELECT Shop_ID, Is_full_time, Start_from FROM hiring WHERE Start_from <> "2012" AND "Shop_ID" <> 1 AND Is_full_time != "F"


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 > 2


Question: SELECT id FROM albums WHERE "id" = 319 OR "artist_id" <= 22 UNION ALL SELECT id FROM employees WHERE title <> "Sales Support Agent" AND email <> "margaret@chinookcorp.com" AND country <> "Canada" AND postal_code != "T3B 1Y7" AND "id" <> 6 AND "reports_to" <= 1.0 AND first_name = "Nancy" AND city != "Lethbridge" AND state <> "AB" OR hire_date <> "2002-08-14 00:00:00" AND birth_date = "1968-01-09 00:00:00"


Question: SELECT ClubID, ClubDesc, ClubLocation, ClubName FROM Club WHERE ClubName = "Bootup Baltimore" AND ClubDesc = "Venture capital fund for student business." UNION SELECT ClubID, ClubDesc, ClubLocation, ClubName FROM Club WHERE ClubName != "Bootup Baltimore" AND ClubLocation <> "AKW" OR "ClubID" = 4

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

4
A competitive tennis club.
AKW
Tennis Club


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 = 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 10


Question: SELECT i_id, title FROM item WHERE "i_id" <> 4 INTERSECT SELECT i_id, title FROM item WHERE "i_id" >= 6


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


Question: SELECT state FROM AREA_CODE_STATE WHERE state <> "KS" AND "area_code" <= 562 UNION SELECT state FROM VOTES WHERE "phone_number" <> 5112677315 AND created != "2018-03-09 19:03:40"


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 = 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 > 8 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 < 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 = 2


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 <= 6 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT age, born_state, name, head_ID FROM head WHERE "age" != 50.0 OR name = "Dudley Hart" EXCEPT SELECT age, born_state, name, head_ID FROM head WHERE born_state = "Connecticut" AND "head_ID" <> 1 OR "age" >= 53.0


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 Club_ID FROM club WHERE Club_name != "Gefle IF" AND Region <> "France" AND "Club_ID" != 5 UNION SELECT Club_ID FROM match_result WHERE "Big_Silver" <> 12 AND "Rank" <= 4 OR "Gold" < 5 OR "Bronze" = 9 AND "Small_Silver" = 4 OR "Club_ID" = 6


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 = 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 < 11 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 != 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 <> 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 9


Question: SELECT Comptroller, Year FROM party WHERE "Party_ID" < 7 AND Party != "Independence" AND Attorney_General <> "Eliot Spitzer" OR Comptroller = "Alan Hevesi" OR US_Senate != "(no election)" OR "Year" <> 2006.0 UNION SELECT Comptroller, Year FROM party WHERE "Party_ID" <> 3 OR Governor = "Betsy McCaughey Ross" AND US_Senate = "Hillary Rodham Clinton" AND "Year" > 2006.0 OR Attorney_General <> "Andrew Cuomo" AND Lieutenant_Governor != "David Paterson" OR Comptroller != "Alan Hevesi" AND Party <> "Democratic"


Question: SELECT AVG(Branch_ID), SUM(Register_Year) FROM membership_register_branch WHERE "Member_ID" < 8 UNION SELECT AVG(Branch_ID), SUM(Register_Year) FROM membership_register_branch WHERE "Member_ID" != 1


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 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 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 != 7


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 AVG(T1.City_Population), T2.District_ID FROM district as T1 JOIN store_district as T2 ON T1.District_ID = T2.District_ID WHERE "City_Area" = 25.0 OR "Store_ID" <= 4 OR Headquartered_City <> "Chiniot City" AND District_name <> "Gujrat District" OR "City_Population" <= 1526168.0 GROUP BY District_name HAVING City_Area <> 12.0 OR City_Population = 2793721.0


Question: SELECT AVG(PetID) FROM Has_Pet WHERE "StuID" <> 1001 UNION ALL SELECT AVG(PetID) FROM Pets WHERE PetType != "dog" OR "pet_age" < 2 AND "weight" < 13.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 = 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 <= 3


Question: SELECT aid FROM certificate WHERE "eid" < 242518965 EXCEPT SELECT aid FROM flight WHERE arrival_date = "04/12/2005 05:03" AND "distance" = 1749 OR destination = "Dallas" OR "aid" > 10 OR "flno" > 13 OR origin = "Los Angeles" AND "price" < 220.98


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 document_id, draft_number FROM Circulation_History WHERE "draft_number" != 1 AND "employee_id" < 2 AND "document_id" <= 1 OR "copy_number" = 4 UNION SELECT document_id, draft_number FROM Document_Drafts WHERE "document_id" = 10 OR "draft_number" > 20 OR draft_details != "v"


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 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 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 <= 9


Question: SELECT draft_number FROM Document_Drafts WHERE "document_id" > 1 OR "draft_number" < 17 INTERSECT SELECT draft_number FROM Draft_Copies WHERE "copy_number" <> 4 OR "document_id" <= 23


Question: SELECT role_code, role_description FROM Roles WHERE role_code != "PT" AND role_description <> "Editor" EXCEPT SELECT role_code, role_description FROM Roles WHERE role_code = "PT" OR role_description = "Proof Manager"


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 <= 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 7


Question: SELECT Book_ID FROM book WHERE "Book_ID" = 4 UNION ALL SELECT Book_ID FROM publication WHERE Publication_Date != "August 2008" OR "Publication_ID" >= 3 OR "Book_ID" > 9 OR "Price" = 6000000.0 OR Publisher <> "Thomson Reuters"


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 = 3 UNION 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 < 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 1


Question: SELECT ClubDesc, ClubName FROM Club WHERE ClubLocation <> "AKW" AND "ClubID" <> 3 AND ClubName = "Hopkins Student Enterprises" AND ClubDesc <> "A competitive tennis club." UNION ALL SELECT ClubDesc, ClubName FROM Club WHERE ClubLocation = "AKW" OR "ClubID" != 3 OR ClubDesc != "Refurbish computers; teach kids and adults about computer basics."

Refurbish computers; teach kids and adults about computer basics.

Venture capital fund for student business.

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


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 != 4


Question: SELECT Party FROM election WHERE "District" > 1 AND Counties_Represented = "12.2 12B" OR "First_Elected" <= 2002.0 AND Committee <> "Environmental Matters" UNION SELECT Party FROM party WHERE Attorney_General = "Eliot Spitzer"


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 != 10 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 3


Question: SELECT MAX(People_ID), MAX(Birth_Date), Height FROM people WHERE Birth_Date = "April 17, 1987" AND "Height" >= 187.0 UNION ALL SELECT MAX(People_ID), MAX(Birth_Date), Height FROM people WHERE Name <> "Yevgeni Sivozhelez" OR "People_ID" <= 7 OR Nationality <> "Russia" OR "Height" <> 207.0 AND Birth_Date = "April 17, 1987"


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 < 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 > 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 >= 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 = 4


Question: SELECT created, state, contestant_number, vote_id FROM VOTES WHERE "phone_number" <= 7148407040 AND state <> "NJ " EXCEPT SELECT created, state, contestant_number, vote_id FROM VOTES WHERE state = "NY" OR "contestant_number" <= 2 AND created != "2018-03-09 19:03:36" AND "vote_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 Continent, CountryId, CountryName FROM countries WHERE "CountryId" <> 8 EXCEPT SELECT Continent, CountryId, CountryName FROM countries WHERE "CountryId" = 3 OR "Continent" = 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 <= 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 Aircraft_ID FROM aircraft WHERE Aircraft = "Mil Mi-26" OR Max_disk_Loading = "3.7 lb/ft² (18 kg/m²)" AND Total_disk_area <> "4,900 ft² (460 m²)" OR Max_Gross_Weight <> "50,000 lb (22,680 kg)" INTERSECT SELECT Aircraft_ID FROM airport_aircraft WHERE "Aircraft_ID" = 2 OR "ID" != 1 OR "Airport_ID" <= 9


Question: SELECT id FROM albums WHERE title <> "Chill: Brazil (Disc 2)" OR "artist_id" != 142 AND "id" <> 318 INTERSECT SELECT id FROM media_types WHERE "id" < 4 OR name = "AAC audio file"


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 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 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 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 = 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 < 8 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT Shop_ID FROM hiring WHERE "Shop_ID" >= 1 OR "Employee_ID" > 1 AND Is_full_time = "T" INTERSECT SELECT Shop_ID FROM hiring WHERE Start_from != "2010"


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 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 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 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 >= 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 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 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 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 != 5 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT document_id FROM Circulation_History WHERE "document_id" = 1 OR "draft_number" < 17 AND "employee_id" = 2 UNION SELECT document_id FROM Documents_Mailed WHERE "document_id" = 12


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 <= 10 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 10


Question: SELECT Department_ID, COUNT(Creation), COUNT(Name) FROM department WHERE "Num_Employees" > 4487.0 OR Name = "Education" GROUP BY Department_ID HAVING COUNT(Name) >= 1 EXCEPT SELECT Department_ID, COUNT(Creation), COUNT(Name) FROM department WHERE Name != "Transportation" OR "Budget_in_Billions" <= 77.6 AND "Ranking" >= 6 GROUP BY Department_ID HAVING COUNT(Creation) != 1


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 = 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 <> 3 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 <> 5 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 > 4 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 UNION 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 != 2 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID != 5


Question: SELECT role_description, role_code FROM Roles WHERE role_description <> "Proof Manager" AND role_code = "PT" UNION SELECT role_description, role_code FROM Roles WHERE role_code = "PT"


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 != 12 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 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 <> 2 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 1


Question: SELECT phone_number, contestant_number, vote_id, created, state FROM VOTES WHERE state = "NY" OR "contestant_number" >= 2 AND "phone_number" < 7182887233 AND "vote_id" > 2 UNION ALL SELECT phone_number, contestant_number, vote_id, created, state FROM VOTES WHERE "contestant_number" <> 5 OR "vote_id" < 1


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 document_id FROM Documents WHERE shipping_agent_code != "US" OR receipt_number = "124" UNION ALL SELECT document_id FROM Draft_Copies WHERE "document_id" < 23 AND "copy_number" != 15


Question: SELECT AVG(Gender), SUM(Rank) FROM coach WHERE "Rank" <> 5 OR Gender != "M" OR Coach_name <> "Jameson Tomas" OR "Coach_ID" >= 3 UNION SELECT AVG(Gender), SUM(Rank) FROM player WHERE Gender = "M" OR Sponsor_name <> "Winnipeg South" OR Player_name = "Judy Wasylycia-Leis" AND Residence = "Winnipeg" OR Rank = "1st" AND "Player_ID" = 10 AND "Votes" = 5490 OR Occupation = "Student"


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 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 = 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 <> 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT property_feature_description FROM Other_Property_Features WHERE "property_id" = 6 OR "feature_id" <> 2 OR property_feature_description = "doloribus" INTERSECT SELECT property_feature_description FROM Other_Property_Features WHERE "feature_id" != 2


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 MAX(property_type_code) FROM Properties WHERE property_type_code <> "Other" OR oth_feature_2 = "None" AND apt_feature_1 <> "enim" OR shp_feature_3 != "None" INTERSECT SELECT MAX(property_type_code) FROM Ref_Property_Types WHERE property_type_code != "Other"


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 > 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 > 2


Question: SELECT shipping_agent_code FROM Ref_Shipping_Agents WHERE shipping_agent_name != "Ship" OR shipping_agent_description <> "k" INTERSECT SELECT shipping_agent_code FROM Ref_Shipping_Agents WHERE shipping_agent_name <> "Ship" OR shipping_agent_code <> "FE"


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 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 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 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 T1.Transit_Passengers, MAX(T2.Airport_ID) FROM airport as T1 JOIN airport_aircraft as T2 ON T1.Airport_ID = T2.Airport_ID


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 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 role_code FROM Employees WHERE role_code <> "MG" UNION ALL SELECT role_code FROM Roles WHERE role_description <> "Proof Manager"


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 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 <> 1


Question: SELECT donator_name, School_id FROM endowment WHERE "amount" = 9.05 OR "School_id" > 1 UNION ALL SELECT donator_name, School_id FROM endowment WHERE "amount" = 9.73 OR "endowment_id" >= 6


Question: SELECT Model FROM car_names WHERE "MakeId" != 94 OR Model != "amc" OR Make = "oldsmobile cutlass ls" UNION SELECT Model FROM model_list WHERE "Maker" < 4 AND Model = "toyota"


Question: SELECT id FROM albums WHERE "id" >= 185 AND title != "Alcohol Fueled Brewtality Live! [Disc 1]" UNION ALL SELECT id FROM media_types WHERE name = "AAC audio file" OR "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 > 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 vehicle_id FROM Lessons WHERE "lesson_id" != 9 AND "vehicle_id" < 2 OR lesson_status_code = "Completed" OR "staff_id" < 8 EXCEPT SELECT vehicle_id FROM Vehicles WHERE vehicle_details = "Truck" AND "vehicle_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 = 10


Question: SELECT Rank FROM match_result WHERE "Big_Silver" <> 6 OR "Bronze" <> 10 AND "Gold" > 13 UNION ALL SELECT Rank FROM player WHERE Rank = "3rd" AND "Votes" = 2353 OR Occupation <> "Student" OR Sponsor_name != "Kildonan—St. Paul" AND Residence <> "Brandon" AND Gender = "M"


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 contestant_name FROM CONTESTANTS WHERE "contestant_number" <= 2 UNION ALL SELECT contestant_name FROM CONTESTANTS WHERE "contestant_number" != 10


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 = 2


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 StuID FROM Has_Allergy WHERE Allergy <> "Cat" INTERSECT SELECT StuID FROM Student WHERE Sex = "M" AND city_code = "BAL" OR LName <> "Pang" OR "StuID" = 1034


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 T1.aid, T2.aid FROM aircraft as T1 JOIN certificate as T2 ON T1.aid == T2.aid GROUP BY eid HAVING name <> "Airbus A319" AND eid = 142519864


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 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 >= 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 <= 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 = 12 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 != 4


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 > 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 10


Question: SELECT People_ID FROM people WHERE "Height" >= 193.0 EXCEPT SELECT People_ID FROM poker_player WHERE "People_ID" > 7


Question: SELECT MIN(T1.Transit_Passengers), T2.ID FROM airport as T1 JOIN airport_aircraft as T2 ON T1.Airport_ID = T2.Airport_ID


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 <> 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID >= 4


Question: SELECT feature_type_name FROM Ref_Feature_Types WHERE feature_type_code = "Amenity" AND feature_type_name != "Securiyt, eg Burglar Alarm." INTERSECT SELECT feature_type_name FROM Ref_Feature_Types WHERE feature_type_code != "Amenity" OR feature_type_name = "Amenity, eg Pool."


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 < 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 <= 7


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 != 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 = 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 <= 3


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 = 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 < 11 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 > 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 > 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 <> 1 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 < 2