human
Schema:
basketball_match (Team_ID, School_ID, Team_Name, ACC_Regular_Season, ACC_Percent, ACC_Home, ACC_Road, All_Games, All_Games_Percent, All_Home, All_Road, All_Neutral)
university (School_ID, School, Location, Founded, Affiliation, Enrollment, Nickname, Primary_conference)
Please answer with SQL.
assistant
Sure, I understand.
human
Show the enrollment and primary_conference of the oldest college.
assistant
SELECT enrollment , primary_conference FROM university ORDER BY founded LIMIT 1
human
How many schools are in the basketball match?
assistant
SELECT count(DISTINCT school_id) FROM basketball_match
human
How many schools do not participate in the basketball match?
assistant
SELECT count(*) FROM university WHERE school_id NOT IN (SELECT school_id FROM basketball_match)
human
What is the team name and acc regular season score of the school that was founded for the longest time?
assistant
SELECT t2.team_name , t2.ACC_Regular_Season FROM university AS t1 JOIN basketball_match AS t2 ON t1.school_id = t2.school_id ORDER BY t1.founded LIMIT 1
human
What is the highest acc percent score in the competition?
assistant
SELECT acc_percent FROM basketball_match ORDER BY acc_percent DESC LIMIT 1
human
What is the primary conference of the school that has the lowest acc percent score in the competition?
assistant
SELECT t1.Primary_conference FROM university AS t1 JOIN basketball_match AS t2 ON t1.school_id = t2.school_id ORDER BY t2.acc_percent LIMIT 1 ;