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


Question: SELECT Player_ID, Coach_ID, Starting_year FROM player_coach WHERE "Player_ID" != 14 OR "Coach_ID" = 3 AND "Starting_year" = 2010 UNION SELECT Player_ID, Coach_ID, Starting_year FROM player_coach WHERE "Player_ID" < 6 AND "Coach_ID" <= 3 OR "Starting_year" = 2012


Question: SELECT Member_ID FROM member WHERE Hometown != "Red Jacket, West Virginia" OR Name = "Matt Lentz" AND "Member_ID" < 7 AND "Level" <= 6 OR Card_Number != "LCB7" UNION ALL SELECT Member_ID FROM purchase WHERE Year <> "2018" OR Branch_ID != "6"


Question: SELECT Gender, Rank FROM coach WHERE Coach_name != "Jameson Tomas" AND "Coach_ID" > 3 OR "Rank" != 1 OR Gender != "M" AND "Club_ID" >= 3 UNION ALL SELECT Gender, Rank FROM player WHERE Occupation <> "Student" AND Gender <> "F" AND Sponsor_name != "Selkirk—Interlake" AND Residence <> "Birtle" OR "Votes" <> 5502 OR Rank = "2nd" OR "Player_ID" <> 3 OR Player_name = "Judy Wasylycia-Leis"


Question: SELECT Issues FROM book WHERE "Book_ID" > 3 AND Title <> "Gemini Blood" OR "Issues" <= 9.0 NOT IN (SELECT Issues FROM book WHERE Title <> "Michael Moorcock's Multiverse" AND "Book_ID" > 6 AND "Issues" <= 4.0 OR Writer != "Garth Ennis")


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


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


Question: SELECT document_id FROM Documents_Mailed WHERE "document_id" <> 13 OR "mailed_to_address_id" > 8 AND mailing_date = "1993-05-24 22:13:48" UNION SELECT document_id FROM Draft_Copies WHERE "draft_number" <> 20


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


Question: SELECT Country, Id, Maker, FullName FROM car_makers WHERE Country != "1" OR FullName != "Nissan Motors" EXCEPT SELECT Country, Id, Maker, FullName FROM car_makers WHERE "Id" > 7 AND Maker <> "volvo"


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


Question: SELECT Name, Age, People_ID, Graduation_College FROM people WHERE "People_ID" >= 7 OR Nationality = "United Kindom" OR "Age" < 37 INTERSECT SELECT Name, Age, People_ID, Graduation_College FROM people WHERE "People_ID" < 4 OR "Age" >= 27


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 employee_id FROM Circulation_History WHERE "draft_number" != 2 OR "document_id" != 10 AND "employee_id" >= 2 UNION ALL SELECT employee_id FROM Employees WHERE employee_name = "Kenyon" AND other_details = "v"


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 10 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 City_Population, District_name, Headquartered_City, District_ID, City_Area FROM district WHERE "District_ID" != 4 AND "City_Area" > 15.0 OR Headquartered_City = "Kasur City" INTERSECT SELECT City_Population, District_name, Headquartered_City, District_ID, City_Area FROM district WHERE District_name = "Khanewal District" OR "City_Population" >= 464742.0


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


Question: SELECT id FROM albums WHERE title <> "The Doors" UNION SELECT id FROM playlists WHERE "id" > 16 AND name != "On-The-Go 1"


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 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 > 4 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 3


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


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


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


Question: SELECT COUNT(T1.amount_payment), T2.cell_mobile_phone_number FROM Customer_Payments as T1 JOIN Customers as T2 ON T1.customer_id = T2.customer_id WHERE payment_method_code <> "Direct Debit" AND datetime_payment = "2018-02-06 13:35:58" AND customer_status_code = "Good Customer" AND phone_number <> "(662)490-3108" OR amount_payment = 1708.18 OR date_became_customer = "2017-10-05 14:15:46" AND date_of_birth = "1998-09-18 04:45:01" OR amount_outstanding >= 9332.0 OR email_address = "kroberts@example.org"


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


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


Question: SELECT Store_ID FROM store WHERE Store_Name = "Miramichi" AND "Number_of_product_category" <> 793.0 OR "Area_size" != 26.69 UNION SELECT Store_ID FROM store_product WHERE "Product_ID" <> 3


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 School_id FROM School WHERE IHSAA_Football_Class != "AAA" OR School_name = "Triton" OR Mascot <> "Cougars" UNION SELECT School_id FROM budget WHERE "School_id" < 2 OR "Budgeted" <= 3666 OR "total_budget_percent_invested" >= 2.2 OR "Invested" >= 8335 OR Budget_invested_percent = "122.5" OR "Year" != 2001 OR "total_budget_percent_budgeted" < 2.0


Question: SELECT Model FROM car_names WHERE Make <> "toyota corona liftback" OR "MakeId" = 25 AND Model != "ford" EXCEPT SELECT Model FROM model_list WHERE "ModelId" > 18 OR "Maker" = 2 OR Model = "peugeot"


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


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


Question: SELECT Paragraph_Text, MIN(Other_Details), Document_ID, MIN(Paragraph_ID) FROM Paragraphs WHERE "Paragraph_ID" > 9946 OR "Document_ID" <= 80 OR Paragraph_Text = "UK" OR Other_Details <> "None" UNION ALL SELECT Paragraph_Text, MIN(Other_Details), Document_ID, MIN(Paragraph_ID) FROM Paragraphs WHERE Other_Details = "None"


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


Question: SELECT contestant_name, contestant_number FROM CONTESTANTS WHERE "contestant_number" <= 10 UNION SELECT contestant_name, contestant_number FROM CONTESTANTS WHERE "contestant_number" >= 3 AND contestant_name = "Jessie Alloway"


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 Book_ID FROM book WHERE "Issues" <> 12.0 EXCEPT SELECT Book_ID FROM publication WHERE Publication_Date <> "October 2005" AND "Price" != 15000000.0


Question: SELECT School_ID FROM school WHERE School = "Columbia University" AND Grade = "Kindergarten" AND "School_ID" < 2 OR Type = "Private" OR Location <> "Jakarta, Indonesia" EXCEPT SELECT School_ID FROM school_bus WHERE "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 <= 9


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


Question: SELECT District, Election_ID, Counties_Represented FROM election WHERE "Party" >= 7 OR "Election_ID" >= 1 OR Delegate <> "Bates, Gail H. Gail H. Bates" UNION SELECT District, Election_ID, Counties_Represented FROM election WHERE Committee = "Appropriations"


Question: SELECT Rank, Club_ID FROM coach WHERE Coach_name != "James Wong" OR "Rank" < 3 AND Gender != "F" AND "Coach_ID" != 4 EXCEPT SELECT Rank, Club_ID FROM match_result WHERE "Club_ID" != 4 OR "Rank" > 5 OR "Bronze" >= 8 AND "Small_Silver" = 16 AND "Points" = 84 AND "Gold" != 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 = 5


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


Question: SELECT feature_type_name FROM Ref_Feature_Types WHERE feature_type_name <> "Amenity, eg Pool." UNION ALL SELECT feature_type_name FROM Ref_Feature_Types WHERE feature_type_code = "Security" AND feature_type_name <> "Amenity, eg Pool."


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


Question: SELECT ClubID FROM Club WHERE ClubName <> "Bootup Baltimore" UNION ALL SELECT ClubID FROM Member_of_club WHERE Position <> "Vice-President" AND "ClubID" <= 2 AND "StuID" < 1010


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


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


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


Question: SELECT Store_ID FROM store_district WHERE "District_ID" >= 4 OR "Store_ID" < 4 UNION ALL SELECT Store_ID FROM store_product WHERE "Product_ID" = 1


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 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 <= 5 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID > 3


Question: SELECT Branch_ID, Member_ID, Year FROM purchase WHERE Year <> "2018" AND "Member_ID" < 2 UNION ALL SELECT Branch_ID, Member_ID, Year FROM purchase WHERE "Member_ID" >= 6 OR "Total_pounds" >= 232.09 AND Year != "2018" OR Branch_ID != "5"


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


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


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


Question: SELECT City_Population, District_name, MIN(City_Area) FROM district WHERE District_name != "Faisalabad District" OR "City_Area" < 75.0 OR Headquartered_City = "Chakwal City" OR "City_Population" != 172073.0 UNION ALL SELECT City_Population, District_name, MIN(City_Area) FROM district WHERE Headquartered_City = "Khanewal City" AND "City_Area" > 147.0 OR District_name <> "Hafizabad District"


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 Name FROM employee WHERE City <> "Bristol" EXCEPT SELECT Name FROM shop WHERE Manager_name <> "Pekka Lyyski"


Question: SELECT document_id FROM Documents_Mailed WHERE "document_id" > 4 OR "mailed_to_address_id" != 4 INTERSECT SELECT document_id FROM Draft_Copies WHERE "copy_number" = 4


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <= 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 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 > 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 > 6 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 = 3


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


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 5 INTERSECT SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <= 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 >= 9


Question: SELECT SUM(T1.ClubID), T2.StuID FROM Club as T1 JOIN Member_of_club as T2 ON T1.ClubID = T2.ClubID WHERE Position = "President" AND ClubName <> "Hopkins Student Enterprises"


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 6 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 >= 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 >= 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 != 6 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


Question: SELECT Id FROM car_makers WHERE FullName <> "Renault" AND Country != "1" OR "Id" != 7 UNION ALL SELECT Id FROM cars_data WHERE MPG <> "26.5" AND Horsepower <> "67" AND "Id" > 34


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


Question: SELECT Member_ID, Total_pounds, Year FROM purchase WHERE "Member_ID" >= 4 EXCEPT SELECT Member_ID, Total_pounds, Year FROM purchase WHERE Branch_ID = "3" AND Year = "2018"


Question: SELECT mailing_date, document_id, mailed_to_address_id FROM Documents_Mailed WHERE "mailed_to_address_id" <= 8 OR mailing_date = "2007-01-01 22:32:11" AND "document_id" != 23 EXCEPT SELECT mailing_date, document_id, mailed_to_address_id FROM Documents_Mailed WHERE mailing_date <> "1971-11-03 12:32:14"


Question: SELECT Graduation_College FROM people WHERE Name != "Reggie Lewis" INTERSECT SELECT Graduation_College FROM people WHERE "Age" >= 31 AND Graduation_College != "Northeastern"


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 >= 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 = 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 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 feature_id FROM Other_Available_Features WHERE feature_name != "AirCon" UNION ALL SELECT feature_id FROM Other_Property_Features WHERE "feature_id" = 2 OR "property_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(shipping_agent_code), shipping_agent_description FROM Ref_Shipping_Agents WHERE shipping_agent_code = "UP" INTERSECT SELECT SUM(shipping_agent_code), shipping_agent_description FROM Ref_Shipping_Agents WHERE shipping_agent_code = "UP" OR shipping_agent_name = "Airline"


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 MAX(feature_type_code), feature_description FROM Other_Available_Features WHERE feature_name = "AirCon" OR feature_description = "Air Conditioning." AND "feature_id" >= 3 UNION ALL SELECT MAX(feature_type_code), feature_description FROM Other_Available_Features WHERE "feature_id" <> 2 AND feature_type_code = "Security" OR feature_description = "Swimming Pool."


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 eid FROM certificate WHERE "eid" >= 269734834 UNION ALL SELECT eid FROM employee WHERE name = "William Moore" OR "eid" != 356187925


Question: SELECT MAX(Fname), city_code, Age, MAX(Major) FROM Student WHERE city_code = "ATL" OR LName = "Andreou" AND Fname = "Charles" OR "Advisor" >= 7712 AND Sex <> "M" AND "Major" = 520 AND "Age" > 19 OR "StuID" <= 1001 UNION SELECT MAX(Fname), city_code, Age, MAX(Major) FROM Student WHERE Sex = "M" AND city_code != "HOU" OR "StuID" >= 1022


Question: SELECT MAX(Address_road) FROM branch WHERE "Branch_ID" != 5 AND Address_road <> "Oaks Crescent" OR Open_year <> "2014" IN (SELECT MAX(Address_road) FROM branch WHERE Open_year = "2001")


Question: SELECT Employee_ID FROM evaluation WHERE Employee_ID = "1" UNION SELECT Employee_ID FROM hiring WHERE Start_from != "2011" AND Is_full_time != "T" OR "Shop_ID" = 4


Question: SELECT SUM(Document_ID) FROM Documents WHERE "Document_ID" <> 3830 OR Document_Name <> "Summer Show" AND Document_Description = "y" OR Other_Details <> "None" AND "Template_ID" >= 1 UNION ALL SELECT SUM(Document_ID) FROM Paragraphs WHERE Other_Details <> "None" OR "Paragraph_ID" <= 765713812 OR Paragraph_Text <> "Fiji"


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


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


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


Question: SELECT property_type_code, property_type_description FROM Ref_Property_Types WHERE property_type_description = "Other, to be determined." OR property_type_code <> "Other" UNION SELECT property_type_code, property_type_description FROM Ref_Property_Types WHERE property_type_description = "House, Bungalow, etc." OR property_type_code != "Apartment"


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


Question: SELECT COUNT(document_id) FROM Document_Drafts WHERE "document_id" <= 17 UNION ALL SELECT COUNT(document_id) FROM Documents WHERE document_type_code != "Paper" AND receipt_date = "1996-05-31 06:51:58" OR shipping_agent_code = "US" AND "document_id" != 2 AND document_status_code <> "overdue" AND receipt_number = "189" OR other_details <> "r"


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


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID <> 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 = 1 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


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


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


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


Question: SELECT SUM(Nationality), Birth_Date, Name, MAX(People_ID), SUM(Height) FROM people WHERE "People_ID" <> 7 AND Name != "Teodor Salparov" OR "Height" <> 194.0 AND Nationality = "Russia" OR Birth_Date != "May 26, 1986" UNION ALL SELECT SUM(Nationality), Birth_Date, Name, MAX(People_ID), SUM(Height) FROM people WHERE "Height" >= 205.0 OR "People_ID" > 3 OR Name != "Roman Bragin" AND Birth_Date <> "February 8, 1981"


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 eid FROM certificate WHERE "eid" < 550156548 OR "aid" >= 10 UNION ALL SELECT eid FROM employee WHERE name = "Michael Miller"


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


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


Question: SELECT Starting_year, Coach_ID FROM player_coach WHERE "Starting_year" > 2011 OR "Player_ID" = 1 INTERSECT SELECT Starting_year, Coach_ID FROM player_coach WHERE "Starting_year" <= 2011 AND "Player_ID" < 4 OR "Coach_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 > 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 >= 3


Question: SELECT MAX(Population), County_Id, COUNT(Zip_code), COUNT(County_name) FROM county WHERE Zip_code != "D11" AND County_name <> "Colony" OR "County_Id" < 5 GROUP BY County_Id HAVING COUNT(Zip_code) = 1 INTERSECT SELECT MAX(Population), County_Id, COUNT(Zip_code), COUNT(County_name) FROM county WHERE "Population" > 21000.0 OR Zip_code != "D21" GROUP BY County_Id HAVING MAX(Population) <> 87200.0 AND COUNT(County_name) = 1 OR COUNT(Zip_code) > 1


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


Question: SELECT 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 < 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 <> 7


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


Question: SELECT Aircraft_ID FROM aircraft WHERE Description <> "Tandem rotor helicopter" OR Max_Gross_Weight = "3,200 lb (1,451 kg)" OR Aircraft != "CH-47D Chinook" OR "Aircraft_ID" = 3 AND Max_disk_Loading <> "8.8 lb/ft² (43 kg/m²)" UNION ALL SELECT Aircraft_ID FROM airport_aircraft WHERE "Aircraft_ID" <= 3 OR "ID" < 1 OR "Airport_ID" < 2


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


Question: SELECT i_id FROM item WHERE title <> "comb" UNION ALL SELECT i_id FROM review WHERE "rating" > 5 OR "a_id" >= 4 AND "u_id" != 2


Question: SELECT T1.Airport_ID, COUNT(T2.Aircraft_ID) FROM airport as T1 JOIN airport_aircraft as T2 ON T1.Airport_ID = T2.Airport_ID


Question: SELECT AVG(T1.District), T2.Comptroller FROM election as T1 JOIN party as T2 ON T1.Party = T2.Party WHERE Lieutenant_Governor <> "Jonathan Reiter" OR "Year" <= 2006.0


Question: SELECT Profits_in_Billion FROM company WHERE "Sales_in_Billion" = 68.7 AND "Company_ID" <> 10.0 OR Industry != "Oil and gas" OR "Market_Value_in_Billion" != 202.2 OR Headquarters = "Germany" AND "Profits_in_Billion" < 15.7 UNION ALL SELECT Profits_in_Billion FROM company WHERE "Sales_in_Billion" > 62.4


Question: SELECT MAX(departure_date), AVG(arrival_date), AVG(aid), origin, AVG(destination), COUNT(flno), SUM(price), COUNT(distance) FROM flight WHERE arrival_date <> "04/12/2005 05:03" AND departure_date = "04/12/2005 06:30" AND "flno" > 76 UNION SELECT MAX(departure_date), AVG(arrival_date), AVG(aid), origin, AVG(destination), COUNT(flno), SUM(price), COUNT(distance) FROM flight WHERE departure_date != "04/12/2005 12:45" AND "distance" <> 5478 OR "aid" >= 5 AND arrival_date = "04/12/2005 10:03" AND "flno" = 76

MAX(departure_date) AVG(arrival_date) AVG(aid) origin AVG(destination) COUNT(flno) SUM(price) COUNT(distance)


Question: SELECT COUNT(City_Population), MAX(District_ID), Headquartered_City, COUNT(District_name) FROM district WHERE "District_ID" >= 2 OR Headquartered_City != "Faisalabad City" AND "City_Population" >= 172073.0 OR District_name = "Attock District" OR "City_Area" = 10.0 UNION ALL SELECT COUNT(City_Population), MAX(District_ID), Headquartered_City, COUNT(District_name) FROM district WHERE "City_Area" <> 25.0 OR District_name != "Chiniot District" AND Headquartered_City = "Gujrat City" AND "City_Population" < 113524.0


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


Question: SELECT document_id, draft_number FROM Circulation_History WHERE "employee_id" <> 8 AND "draft_number" <> 20 AND "copy_number" >= 5 AND "document_id" > 10 UNION ALL SELECT document_id, draft_number FROM Circulation_History WHERE "copy_number" = 5 OR "document_id" >= 20


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 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 StuID FROM Has_Pet WHERE "StuID" > 1001 UNION ALL SELECT StuID FROM Student WHERE "Major" = 600


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 Document_Description, Template_ID FROM Documents WHERE Document_Description <> "b" UNION SELECT Document_Description, Template_ID FROM Documents WHERE Document_Description != "y" OR Document_Name <> "How to read a book" OR "Template_ID" > 14


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


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


Question: SELECT AVG(Book_ID) FROM book WHERE "Issues" >= 4.0 OR Title <> "Dead Corps" AND "Book_ID" >= 3 AND Writer <> "Howard Chaykin" UNION ALL SELECT AVG(Book_ID) FROM publication WHERE "Book_ID" <= 3 OR Publication_Date = "August 2008" AND "Price" <> 2000000.0


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


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


Question: SELECT COUNT(customer_id) FROM Customers WHERE phone_number <> "1-875-045-0806" UNION SELECT COUNT(customer_id) FROM Lessons WHERE "staff_id" <> 8 OR lesson_status_code != "Cancelled" OR lesson_time = "5"


Question: SELECT Age, AVG(Major), COUNT(Sex) FROM Student WHERE LName != "Prater" OR Sex <> "F" AND "Advisor" >= 1121 OR "Major" <> 600 AND "Age" <= 18 OR "StuID" = 1005 UNION SELECT Age, AVG(Major), COUNT(Sex) FROM Student WHERE Sex = "F" AND "StuID" > 1032 OR Fname = "Eric" AND "Age" >= 20 OR "Advisor" >= 7792 AND city_code = "LON"


Question: SELECT SUM(Name) FROM shop WHERE District = "Tehtaan kenttä" OR Location != "Turku" AND Name != "IFK Mariehamn" AND "Number_products" >= 10000 OR Manager_name != "Pekka Lyyski" UNION ALL SELECT SUM(Name) FROM shop WHERE Location <> "Lahti"


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


Question: SELECT role_code FROM Employees WHERE role_code <> "PR" INTERSECT SELECT role_code FROM Roles WHERE role_code = "ED" OR role_description <> "Manager"


Question: SELECT Location, School_ID, School, Type FROM school WHERE Type != "Private" AND Location = "New York City" AND "School_ID" > 4 OR School <> "Punahou School" UNION ALL SELECT Location, School_ID, School, Type FROM school WHERE School = "Columbia University" AND Location != "Jakarta, Indonesia"

Honolulu, Hawaii
1
Noelani Elementary School
Public

Jakarta, Indonesia
2
St. Francis Assisi
Private Catholic

Jakarta, Indonesia
3
State Elementary School Menteng 01
Public

Los Angeles, California
5
Occidental College
Private

New York City
6
Columbia University
Private

Cambridge, Massachusetts
7
Harvard Law School
Private

New York City
6
Columbia University
Private


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


Question: SELECT salary, name, eid FROM employee WHERE name != "William Moore" AND "eid" != 287321212 UNION SELECT salary, name, eid FROM employee WHERE "salary" <= 23980


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


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID != 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 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 MAX(T1.Enrollment), T2.Invested FROM School as T1 JOIN budget as T2 ON T1.School_id = T2.School_id WHERE Year <= 2005 OR COUNT(Invested) < 5840 AND IHSAA_Class = "AAA" AND IHSAA_Football_Class <> "A" AND COUNT(total_budget_percent_budgeted) < 2.0 AND Enrollment <= 620 OR Location <> "Culver"


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


Question: SELECT payment_method_code, customer_id, amount_payment FROM Customer_Payments WHERE "amount_payment" <> 6970.98 AND datetime_payment != "2018-02-27 20:08:53" INTERSECT SELECT payment_method_code, customer_id, amount_payment FROM Customer_Payments WHERE datetime_payment != "2018-02-24 10:07:05" OR "amount_payment" >= 4773.16 OR "customer_id" > 6 OR payment_method_code <> "Direct Debit"


Question: SELECT Gold, SUM(Bronze), Club_ID, Big_Silver, Points, Rank, MIN(Small_Silver) FROM match_result WHERE "Rank" <> 2 OR "Bronze" > 6 OR "Big_Silver" >= 12 AND "Club_ID" <= 5 OR "Gold" <= 7 EXCEPT SELECT Gold, SUM(Bronze), Club_ID, Big_Silver, Points, Rank, MIN(Small_Silver) FROM match_result WHERE "Gold" = 7 AND "Big_Silver" > 12


Question: SELECT IATA, City, Country, ICAO, name, id FROM airport WHERE IATA != "AMS" AND ICAO != "ENBR" EXCEPT SELECT IATA, City, Country, ICAO, name, id FROM airport WHERE name != "National Airport" AND City = "Baltimore" OR ICAO <> "EKBI" OR "id" <= 1 AND IATA <> "BRU"

BLL
Billund
Denmark
EKBI
Billund Airport
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 <> 12 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 7


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


Question: SELECT SUM(id) FROM flight WHERE Vehicle_Flight_number = "M2-F1 #70" AND "company_id" <= 13 UNION ALL SELECT SUM(id) FROM operate_company WHERE name = "Cathay Pacific Catering Services (HK) Limited" OR "id" = 7 OR "Group_Equity_Shareholding" < 100.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 <= 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 < 9


Question: SELECT SUM(draft_number), MIN(document_id) FROM Document_Drafts WHERE "document_id" = 13 AND "draft_number" >= 16 UNION ALL SELECT SUM(draft_number), MIN(document_id) FROM Draft_Copies WHERE "document_id" <= 1 OR "draft_number" >= 17 OR "copy_number" > 10


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


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


Question: SELECT People_ID FROM people WHERE "People_ID" > 5 AND "Height" >= 187.0 EXCEPT SELECT People_ID FROM poker_player WHERE "Money_Rank" >= 166.0 AND "Poker_Player_ID" >= 2 AND "People_ID" = 5 AND "Best_Finish" = 3.0 AND "Final_Table_Made" != 10.0 OR "Earnings" < 189233.0


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 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 >= 9 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 4


Question: SELECT MIN(City) FROM airport WHERE IATA = "BCN" AND ICAO != "LEBL" OR Country != "Denmark" INTERSECT SELECT MIN(City) FROM airport WHERE City = "Baltimore" OR IATA <> "BWI" OR Country <> "Spain" OR name = "El Prat Airport" OR "id" = 1


Question: SELECT id FROM albums WHERE title <> "The Best Of 1980-1990" EXCEPT SELECT id FROM media_types WHERE name = "AAC audio file" OR "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 = 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID = 9


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 2 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 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 >= 5


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


Question: SELECT PetID, StuID FROM Has_Pet WHERE "StuID" <= 1002 UNION ALL SELECT PetID, StuID FROM Has_Pet WHERE "StuID" > 1002 OR "PetID" <> 2003


Question: SELECT property_type_description FROM Ref_Property_Types WHERE property_type_code != "Apartment" AND property_type_description <> "Apartment, Flat, Condo, etc." EXCEPT SELECT property_type_description FROM Ref_Property_Types WHERE property_type_description != "Shop, Retail Outlet." OR property_type_code = "House"


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


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


Question: SELECT Aircraft_ID FROM aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2 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 > 1 UNION SELECT Aircraft_ID FROM airport_aircraft GROUP BY Aircraft_ID HAVING Aircraft_ID < 2


Question: SELECT COUNT(id) FROM albums WHERE "artist_id" != 51 UNION SELECT COUNT(id) FROM genres WHERE name = "Science Fiction" OR "id" < 23


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


Question: SELECT origin, aid, price, distance, destination FROM flight WHERE arrival_date = "04/12/2005 07:05" AND destination = "Washington D.C." AND "aid" > 1 OR "flno" != 34 AND departure_date <> "04/12/2005 09:00" OR "price" > 220.98 UNION ALL SELECT origin, aid, price, distance, destination FROM flight WHERE origin = "Chicago" OR departure_date != "04/12/2005 11:50"


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


Question: SELECT state FROM AREA_CODE_STATE WHERE state != "VA" UNION SELECT state FROM VOTES WHERE "phone_number" <= 6209222712 OR created != "2018-03-09 19:03:39" AND "vote_id" = 1


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


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


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


Question: SELECT eid FROM employee WHERE "salary" > 20 OR "eid" < 90873519 EXCEPT SELECT eid FROM employee WHERE "eid" >= 242518965 AND name != "Michael Miller" AND "salary" >= 105743


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


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 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 > 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 >= 1 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 10


Question: SELECT MAX(Branch_ID), Open_year, AVG(membership_amount) FROM branch WHERE Address_road != "Brampton Road" OR membership_amount != "11" AND "Branch_ID" <= 1 AND City = "Oxford" AND Name <> "Alexandre" UNION ALL SELECT MAX(Branch_ID), Open_year, AVG(membership_amount) FROM branch WHERE Name != "Stanley" AND Open_year = "2014" AND membership_amount != "11" AND City = "London" AND "Branch_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 > 3


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


Question: SELECT Name, MIN(Party), Age, SUM(Driver_ID), Home_city FROM driver WHERE "Driver_ID" != 10 AND Name = "Henry Genga" UNION ALL SELECT Name, MIN(Party), Age, SUM(Driver_ID), Home_city FROM driver WHERE Party != "Dem"


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 5 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 >= 4


Question: SELECT MAX(Store_ID) FROM store WHERE "Number_of_product_category" > 1678.0 UNION SELECT MAX(Store_ID) FROM store_district WHERE "Store_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 >= 9


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 District_ID FROM store_district WHERE "Store_ID" <> 1 UNION ALL SELECT District_ID FROM store_district WHERE "Store_ID" <> 2 OR "District_ID" <= 3


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


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


Question: SELECT draft_number, document_id FROM Document_Drafts WHERE draft_details = "k" OR "draft_number" <= 1 AND "document_id" <> 12 INTERSECT SELECT draft_number, document_id FROM Draft_Copies WHERE "document_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 <= 9


Question: SELECT date_joined_staff, last_name, nickname, staff_id, staff_address_id, first_name, date_left_staff FROM Staff WHERE nickname <> "norma73" OR date_of_birth <> "1998-04-27 12:55:05" UNION SELECT date_joined_staff, last_name, nickname, staff_id, staff_address_id, first_name, date_left_staff FROM Staff WHERE first_name != "Titus" OR "staff_address_id" <> 1 AND last_name != "Mertz" AND middle_name <> "Stephania"


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 Grade, Type, School FROM school WHERE School != "St. Francis Assisi" INTERSECT SELECT Grade, Type, School FROM school WHERE Type <> "Public" AND School <> "State Elementary School Menteng 01"

Freshman–Sophomore year
Private
Occidental College

Junior–Senior year
Private
Columbia University


Question: SELECT employee_id FROM Circulation_History WHERE "copy_number" != 4 OR "document_id" = 10 OR "draft_number" <> 20 OR "employee_id" >= 2 UNION SELECT employee_id FROM Employees WHERE employee_name = "Kenyon"


Question: SELECT aid FROM aircraft WHERE "aid" <= 10 OR "distance" > 3383 OR name = "Airbus A320" GROUP BY aid HAVING aid <> 9 INTERSECT SELECT aid FROM aircraft WHERE "distance" > 1805 OR name != "Airbus A319" OR "aid" <> 5 GROUP BY aid HAVING aid = 3


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


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


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


Question: SELECT Other_Details FROM Documents WHERE Other_Details = "None" AND "Document_ID" = 82 AND Document_Name = "How to write a CV" UNION ALL SELECT Other_Details FROM Paragraphs WHERE Other_Details <> "None" OR "Document_ID" <= 80 OR Paragraph_Text <> "Ukraine"


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


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 Shop_ID, Start_from FROM hiring WHERE "Employee_ID" <> 1 OR Start_from != "2003" UNION ALL SELECT Shop_ID, Start_from FROM hiring WHERE Start_from != "2003" OR "Employee_ID" <= 7 OR "Shop_ID" <> 6


Question: SELECT SUM(Max_disk_Loading), MAX(Max_Gross_Weight), COUNT(Total_disk_area), SUM(Aircraft), COUNT(Description), Aircraft_ID FROM aircraft WHERE "Aircraft_ID" <> 3 UNION ALL SELECT SUM(Max_disk_Loading), MAX(Max_Gross_Weight), COUNT(Total_disk_area), SUM(Aircraft), COUNT(Description), Aircraft_ID FROM aircraft WHERE "Aircraft_ID" = 4 AND Aircraft <> "CH-53E Super Stallion"


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID = 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 != 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 <> 5 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


Question: SELECT MIN(name) FROM aircraft WHERE name <> "Schwitzer 2-33" AND "aid" != 3 OR "distance" > 520 UNION SELECT MIN(name) FROM employee WHERE "salary" <> 256481 OR name = "James Smith"


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID < 9 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 < 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


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


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


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


Question: SELECT 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 >= 2 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 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 >= 10 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <> 7


Question: SELECT Maker FROM car_makers WHERE Maker = "renault" OR Country != "8" AND "Id" = 6 AND FullName = "Chrysler" EXCEPT SELECT Maker FROM model_list WHERE Model != "cadillac"


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


Question: SELECT Rank, Club_ID FROM coach WHERE Gender != "F" OR Coach_name != "Smith Brown" AND "Coach_ID" != 5 AND "Rank" = 2 OR "Club_ID" > 1 UNION SELECT Rank, Club_ID FROM match_result WHERE "Bronze" >= 7 AND "Small_Silver" < 16 AND "Rank" <= 3 OR "Gold" < 20 OR "Big_Silver" >= 7 OR "Club_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 > 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 <> 3 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 10


Question: SELECT COUNT(People_ID) FROM employment WHERE "People_ID" >= 2 AND "Company_ID" = 17 AND "Year_working" >= 2 UNION ALL SELECT COUNT(People_ID) FROM people WHERE "People_ID" != 7 AND Nationality != "United States" AND Name <> "Jerry Corcoran" AND Graduation_College = "California" OR "Age" < 37


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 7 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 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 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 3


Question: SELECT name FROM head WHERE name != "Jeff Maggert" AND "age" < 69.0 INTERSECT SELECT name FROM head WHERE born_state != "Connecticut" AND name = "Sergio García" OR "age" <= 69.0


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


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


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


Question: SELECT School_id FROM School WHERE Mascot = "Redskins" AND School_name != "Culver Community" OR Location != "Walkerton" AND School_id <> "1" UNION ALL SELECT School_id FROM budget WHERE "Invested" < 95542 AND Budget_invested_percent = "127.6"


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


Question: SELECT bedType, MIN(beds), MAX(roomName), COUNT(maxOccupancy) FROM Rooms WHERE RoomId <> "RTE" AND roomName <> "Thrift and accolade" OR "beds" != 2 AND "maxOccupancy" >= 4 UNION ALL SELECT bedType, MIN(beds), MAX(roomName), COUNT(maxOccupancy) FROM Rooms WHERE "maxOccupancy" > 2 AND "beds" <> 2 OR RoomId <> "HBB" AND "basePrice" = 175

bedType MIN(beds) MAX(roomName) COUNT(maxOccupancy)


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 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 city_code FROM Student WHERE Fname = "Charles" OR "Age" != 17 AND city_code = "PEK" AND LName != "Jones" OR Sex <> "M" OR "Major" <= 600 AND "StuID" <= 1020 UNION SELECT city_code FROM Student WHERE LName != "Adams" OR Fname != "Paul" OR "Age" != 22 AND "StuID" > 1001 OR city_code <> "NYC" OR "Advisor" != 8772 OR Sex <> "M"


Question: SELECT document_type_code FROM Documents WHERE document_type_code = "CD" UNION ALL SELECT document_type_code FROM Ref_Document_Types WHERE document_type_description = "u" OR document_type_code = "CD"


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


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


Question: SELECT MAX(document_id) FROM Circulation_History WHERE "copy_number" = 4 AND "draft_number" <= 20 UNION SELECT MAX(document_id) FROM Documents WHERE receipt_date = "1999-04-17 14:19:32" AND document_status_code = "overdue" AND receipt_number = "69"


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 1 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 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 9


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


Question: SELECT MAX(Year_working) FROM employment WHERE "Company_ID" <= 15 AND "People_ID" <= 4 AND "Year_working" = 1 EXCEPT SELECT MAX(Year_working) FROM employment WHERE "Year_working" >= 3


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


Question: SELECT city, line_1_number_building, address_id FROM Addresses WHERE state_province_county <> "WestVirginia" AND line_1_number_building != "3904 Stroman Passage" AND country = "USA" UNION SELECT city, line_1_number_building, address_id FROM Addresses WHERE zip_postcode = "14445" AND city <> "Buckridgehaven" AND country <> "USA" OR line_1_number_building != "9260 Streich Mountain"

Damianfort
4834 Schaefer Light Suite 947
14

Ericamouth
43235 Jazmin Mountain Suite 251
13

Lake Rafaela
29085 Dejah Pine Suite 059
8

Lockmanfurt
56461 Baumbach Well Suite 634
7

South Eugene
37698 Hahn Curve Apt. 572
11

West Edmondview
9260 Streich Mountain
15


Question: SELECT Member_ID FROM member WHERE Name <> "Braxton Kelley" OR Hometown = "Hiram, Georgia" AND "Member_ID" > 9 OR "Level" != 6 OR Card_Number != "MLB4" INTERSECT SELECT Member_ID FROM membership_register_branch WHERE "Member_ID" <= 8 OR Branch_ID != "1" AND Register_Year <> "2016"


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


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


Question: SELECT Template_Details, Version_Number, Template_ID, Template_Type_Code, Date_Effective_From FROM Templates WHERE Template_Type_Code <> "BK" OR Date_Effective_From != "1975-05-20 22:51:19" AND "Template_ID" < 7 AND "Version_Number" = 2 UNION SELECT Template_Details, Version_Number, Template_ID, Template_Type_Code, Date_Effective_From FROM Templates WHERE "Template_ID" <= 21 OR Template_Details = "" AND "Version_Number" >= 7 OR Date_Effective_To != "1989-11-24 19:06:06" AND Date_Effective_From <> "1975-05-20 22:51:19"


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


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


Question: SELECT COUNT(head_ID), MIN(temporary_acting), department_ID FROM management WHERE "head_ID" != 5 OR temporary_acting != "Yes" UNION SELECT COUNT(head_ID), MIN(temporary_acting), department_ID FROM management WHERE temporary_acting <> "Yes" OR "head_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 != 10


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


Question: SELECT Location, Enrollment FROM School WHERE Mascot <> "Jimmies" UNION SELECT Location, Enrollment FROM School WHERE IHSAA_Football_Class = "A" AND School_name <> "Jimtown" AND Mascot != "Lions" OR IHSAA_Class != "AAA" AND School_id <> "1"


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


Question: SELECT If_full_time, MIN(Driver_ID), Years_Working, School_ID FROM school_bus WHERE If_full_time <> "T" UNION SELECT If_full_time, MIN(Driver_ID), Years_Working, School_ID FROM school_bus WHERE "School_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 >= 3 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 3


Question: SELECT Headquartered_City FROM district WHERE Headquartered_City = "Bahawalnagar City" AND "City_Population" >= 172073.0 AND District_name = "Dera Ghazi Khan District" OR "District_ID" > 8 INTERSECT SELECT Headquartered_City FROM district WHERE "District_ID" > 12 OR District_name <> "Chiniot District" OR "City_Area" >= 147.0 OR "City_Population" <= 365198.0


Question: SELECT aid FROM aircraft WHERE "distance" <= 6441 AND "aid" >= 5 OR name <> "Airbus A340-300" UNION SELECT aid FROM certificate WHERE "aid" != 13


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID > 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID > 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 >= 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 > 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 Points FROM match_result WHERE "Rank" != 1 AND "Big_Silver" != 11 AND "Small_Silver" <> 10 AND "Points" >= 139 UNION SELECT Points FROM match_result WHERE "Gold" < 13 AND "Bronze" >= 8 OR "Big_Silver" >= 7 AND "Points" = 89 AND "Club_ID" < 6 OR "Rank" <= 4


Question: SELECT address_id FROM Addresses WHERE "address_id" <> 8 AND address_details != "IE" INTERSECT SELECT address_id FROM Addresses WHERE "address_id" >= 1 AND address_details != "IE"


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


Question: SELECT AllergyType FROM Allergy_Type WHERE Allergy = "Milk" OR AllergyType != "food" NOT IN (SELECT AllergyType FROM Allergy_Type WHERE AllergyType != "food" OR Allergy != "Nuts")


Question: SELECT Member_ID FROM membership_register_branch WHERE Register_Year <> "2016" EXCEPT SELECT Member_ID FROM membership_register_branch WHERE Branch_ID = "4" AND Register_Year <> "2016"


Question: SELECT customer_id, staff_id, lesson_status_code, lesson_id FROM Lessons WHERE "staff_id" < 12 OR lesson_time = "9" AND lesson_status_code != "Cancelled" OR lesson_date = "2018-02-28 10:55:36" AND "customer_id" = 13 OR "vehicle_id" >= 1 AND "price" <> 277.0 OR "lesson_id" > 14 UNION ALL SELECT customer_id, staff_id, lesson_status_code, lesson_id FROM Lessons WHERE lesson_time != "6" OR "price" = 306.0 AND lesson_date <> "2018-03-17 19:02:07" AND "staff_id" <> 5 AND "customer_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 source_u_id, trust FROM trust WHERE "source_u_id" <> 7 AND "target_u_id" >= 2 UNION ALL SELECT source_u_id, trust FROM trust WHERE "source_u_id" = 1 OR "target_u_id" >= 5 OR "trust" > 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 = 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 = 9


Question: SELECT Population FROM county WHERE "Population" <> 79000.0 OR "County_Id" <> 3 OR County_name != "Mansfield" EXCEPT SELECT Population FROM county WHERE "Population" != 21000.0 AND County_name = "Manning" OR Zip_code != "D09" OR "County_Id" <= 1


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


Question: SELECT 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 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 INTERSECT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID < 9


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


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


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


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


Question: SELECT id, City, Country FROM airport WHERE ICAO <> "KBOS" AND "id" <> 3 AND City <> "Boston" AND name <> "Akureyri Airport" OR Country = "Belgium" UNION SELECT id, City, Country FROM airport WHERE ICAO != "EHAM" OR IATA = "AMS" AND name != "Akureyri Airport" AND City = "Barcelona" OR "id" = 9 OR Country = "Belgium"


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


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


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


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


Question: SELECT Final_Table_Made, Earnings, AVG(Poker_Player_ID), SUM(Best_Finish), Money_Rank, MIN(People_ID) FROM poker_player WHERE "Best_Finish" < 1.0 OR "People_ID" < 6 OR "Earnings" <= 189233.0 OR "Final_Table_Made" <> 10.0 AND "Poker_Player_ID" < 4 OR "Money_Rank" <> 68.0 UNION SELECT Final_Table_Made, Earnings, AVG(Poker_Player_ID), SUM(Best_Finish), Money_Rank, MIN(People_ID) FROM poker_player WHERE "Best_Finish" <> 1.0 OR "Poker_Player_ID" > 2 AND "People_ID" != 2 OR "Earnings" <= 189233.0 OR "Money_Rank" <= 166.0


Question: SELECT Branch_ID FROM membership_register_branch WHERE Branch_ID = "1" UNION ALL SELECT Branch_ID FROM purchase WHERE "Total_pounds" >= 20.99 OR Branch_ID <> "3" AND Year <> "2018"


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 Name FROM employee WHERE "Employee_ID" <= 3 UNION ALL SELECT Name FROM shop WHERE "Number_products" <> 10000 OR Location <> "Valkeakoski" AND Name != "FC Honka" OR Manager_name <> "Tommi Kautonen" OR "Shop_ID" != 7 AND District != "Wiklöf Holding Arena"


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


Question: SELECT aid FROM certificate WHERE "aid" = 1 AND "eid" <= 269734834 INTERSECT SELECT aid FROM flight WHERE arrival_date = "04/12/2005 12:02" AND "flno" <= 7 AND "aid" != 6 OR "price" <= 780.99


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


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


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


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


Question: SELECT COUNT(line_1_number_building), COUNT(city), SUM(address_id), country FROM Addresses GROUP BY country HAVING COUNT(line_1_number_building) = 15 OR COUNT(city) != 15 UNION SELECT COUNT(line_1_number_building), COUNT(city), SUM(address_id), country FROM Addresses GROUP BY country HAVING COUNT(line_1_number_building) = 15 OR SUM(address_id) <> 120 AND COUNT(city) > 15


Question: SELECT Continent FROM continents WHERE Continent = "america" UNION ALL SELECT Continent FROM countries WHERE CountryName <> "usa" AND "CountryId" != 10 AND "Continent" >= 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 Club_ID FROM club WHERE "Start_year" <> 1998 AND "Club_ID" <= 1 OR Club_name <> "Halmstads BK" UNION SELECT Club_ID FROM coach WHERE "Rank" >= 4


Question: SELECT Member_ID FROM member WHERE Card_Number = "RE95" OR Hometown <> "Hiram, Georgia" UNION SELECT Member_ID FROM membership_register_branch WHERE "Member_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 Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID >= 4 EXCEPT SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID <= 4


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


Question: SELECT price, flno, arrival_date, destination, distance, aid FROM flight WHERE "price" <= 278.56 INTERSECT SELECT price, flno, arrival_date, destination, distance, aid FROM flight WHERE "price" != 278.56 OR "distance" <= 7487 OR destination <> "Honolulu" OR arrival_date = "04/12/2005 11:10" OR "flno" != 99 AND "aid" >= 9 AND origin <> "Los Angeles"

price flno arrival_date destination distance aid


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 <= 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 Party FROM election WHERE Committee <> "Environmental Matters (Vice-Chair)" AND "Election_ID" >= 4 AND "Party" = 1 OR "First_Elected" = 2003.0 UNION ALL SELECT Party FROM party WHERE Lieutenant_Governor != "Dennis Mehiel" OR "Year" = 1998.0 AND Attorney_General <> "Jeanine Pirro" AND US_Senate <> "(no election)" AND Party = "Democratic" AND "Party_ID" >= 1 AND Governor <> "Carl McCall"


Question: SELECT Club_ID FROM club WHERE Region = "France" OR "Club_ID" <= 3 UNION ALL SELECT Club_ID FROM match_result WHERE "Small_Silver" < 6 AND "Rank" >= 1 OR "Club_ID" < 1 AND "Gold" > 6 OR "Bronze" <= 8


Question: SELECT Member_ID, Hometown, Card_Number FROM member WHERE Card_Number != "LCB7" INTERSECT SELECT Member_ID, Hometown, Card_Number FROM member WHERE Hometown = "Louisville, Kentucky" OR Card_Number = "LCB7"


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


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


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


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


Question: SELECT department_ID, temporary_acting FROM management WHERE temporary_acting != "Yes" UNION ALL SELECT department_ID, temporary_acting FROM management WHERE temporary_acting <> "Yes"


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


Question: SELECT staff_id FROM Lessons WHERE "vehicle_id" >= 1 UNION SELECT staff_id FROM Staff WHERE date_of_birth != "2004-05-19 14:11:13" OR middle_name <> "Stephania" OR first_name != "Ludie" AND last_name <> "Durgan" OR nickname != "norma73" OR date_joined_staff <> "2016-06-05 22:22:23" OR "staff_address_id" < 2 OR "staff_id" <= 12


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


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


Question: SELECT MIN(document_id) FROM Document_Drafts WHERE draft_details != "x" UNION ALL SELECT MIN(document_id) FROM Documents WHERE receipt_number != "61" AND document_type_code <> "Hard Drive"


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 document_id, AVG(draft_number) FROM Circulation_History WHERE "draft_number" >= 20 AND "employee_id" > 1 EXCEPT SELECT document_id, AVG(draft_number) FROM Document_Drafts WHERE draft_details = "r" OR "document_id" != 10


Question: SELECT Employee_ID FROM employee WHERE "Age" > 29 OR City != "Bath" AND "Employee_ID" < 1 INTERSECT SELECT Employee_ID FROM hiring WHERE Is_full_time = "F"


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


Question: SELECT Grade, Location, School FROM school WHERE Grade != "4th grade" OR Location != "Jakarta, Indonesia" AND School = "Noelani Elementary School" INTERSECT SELECT Grade, Location, School FROM school WHERE School = "Occidental College" OR Location = "Cambridge, Massachusetts" OR Type <> "Private" AND Grade != "Freshman–Sophomore year" AND "School_ID" = 4

College
Cambridge, Massachusetts
Harvard Law School

Freshman–Sophomore year
Los Angeles, California
Occidental College


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


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


Question: SELECT COUNT(PetID), MAX(weight), pet_age FROM Pets WHERE "pet_age" >= 2 AND "PetID" = 2001 EXCEPT SELECT COUNT(PetID), MAX(weight), pet_age FROM Pets WHERE PetType != "cat" AND "pet_age" = 3 AND "weight" = 9.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 != 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 < 7


Question: SELECT Member_ID FROM membership_register_branch WHERE "Member_ID" = 2 EXCEPT SELECT Member_ID FROM purchase WHERE "Member_ID" > 3 AND "Total_pounds" >= 20.99


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


Question: SELECT Is_full_time FROM hiring WHERE Start_from = "2003" UNION ALL SELECT Is_full_time FROM hiring WHERE Is_full_time != "F" OR "Shop_ID" <= 1 AND Start_from != "2003"


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


Question: SELECT City, COUNT(Open_year), COUNT(Name), MIN(Branch_ID), Address_road, membership_amount FROM branch WHERE membership_amount <> "6" UNION SELECT City, COUNT(Open_year), COUNT(Name), MIN(Branch_ID), Address_road, membership_amount FROM branch WHERE membership_amount = "56" OR "Branch_ID" <= 3 AND City != "London" OR Address_road <> "Concord Road" OR Name = "Popert" AND Open_year <> "2009"


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


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


Question: SELECT Driver_ID FROM driver GROUP BY Driver_ID HAVING Driver_ID <> 11 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 < 1 UNION SELECT Driver_ID FROM school_bus GROUP BY Driver_ID HAVING Driver_ID != 4


Question: SELECT shipping_agent_description, shipping_agent_name, shipping_agent_code FROM Ref_Shipping_Agents WHERE shipping_agent_description != "g" AND shipping_agent_code <> "UP" UNION SELECT shipping_agent_description, shipping_agent_name, shipping_agent_code FROM Ref_Shipping_Agents WHERE shipping_agent_name != "Airline" OR shipping_agent_description = "q"


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 Employee_ID, Shop_ID, Start_from, Is_full_time FROM hiring WHERE Is_full_time != "T" OR "Employee_ID" = 5 AND Start_from <> "2003" AND "Shop_ID" < 8 UNION SELECT Employee_ID, Shop_ID, Start_from, Is_full_time FROM hiring WHERE "Employee_ID" <> 4 AND "Shop_ID" = 1 OR Is_full_time != "T" OR Start_from <> "2010"


Question: SELECT SUM(Store_ID), MIN(Product_ID) FROM store_product WHERE "Product_ID" = 6 UNION ALL SELECT SUM(Store_ID), MIN(Product_ID) FROM store_product WHERE "Store_ID" < 1 AND "Product_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 eid FROM certificate WHERE "eid" <> 269734834 UNION ALL SELECT eid FROM employee WHERE "eid" <= 348121549


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


Question: SELECT AVG(datetime_payment), AVG(amount_payment), AVG(customer_id), payment_method_code FROM Customer_Payments WHERE "amount_payment" >= 9570.93 UNION SELECT AVG(datetime_payment), AVG(amount_payment), AVG(customer_id), payment_method_code FROM Customer_Payments WHERE payment_method_code != "Credit Card" AND datetime_payment != "2018-02-21 05:28:49" OR "customer_id" <= 2


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


Question: SELECT Model FROM car_names WHERE Model != "volvo" UNION ALL SELECT Model FROM model_list WHERE "ModelId" < 11


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


Question: SELECT SUM(School_id) FROM budget WHERE Budget_invested_percent <> "71.3" AND "Budgeted" != 3666 AND "total_budget_percent_invested" != 2.0 OR "Year" != 2001 AND "Invested" <> 146102 OR "School_id" > 1 UNION ALL SELECT SUM(School_id) FROM endowment WHERE "endowment_id" <= 11 OR donator_name != "La Vega" AND "amount" < 8.99