How many countries has more than 2 car makers ?
create table car_makers (country varchar, PRIMARY KEY (country)); create table countries (countryid varchar, PRIMARY KEY (countryid))
select count(*) from countries as t1 join car_makers as t2 on t1.countryid = t2.country group by t1.countryid having count(*) > 2