How many schools have some students playing in goalie and mid positions.
CREATE TABLE tryout (cName VARCHAR, pPos VARCHAR)
SELECT COUNT(*) FROM (SELECT cName FROM tryout WHERE pPos = 'goalie' INTERSECT SELECT cName FROM tryout WHERE pPos = 'mid')
<s>[INST] Write mssql query to answer the following question given the database schema. Schema: CREATE TABLE tryout (cName VARCHAR, pPos VARCHAR) Question: How many schools have some students playing in goalie and mid positions. [/INST] SELECT COUNT(*) FROM (SELECT cName FROM tryout WHERE pPos = 'goalie' INTERSECT SELECT cName FROM tryout WHERE pPos = 'mid') </s>