qq临时会话网站,专业网站优化推广,海南州公司网站建设,最好的手机资源网站一#xff1a;上码
-- 查询至少生产三种不同速度PC的厂商-- 分析#xff1a;1.联合pc和product表#xff0c;字段为厂商和速度 表1
-- 2.按厂商名字进行分组统计厂商的个数#xff0c;筛选条件为个数大于3的 表2
-- 3.将表2 做为子表筛选出 maker-- 1.
-- selec…一上码
-- 查询至少生产三种不同速度PC的厂商-- 分析1.联合pc和product表字段为厂商和速度 表1
-- 2.按厂商名字进行分组统计厂商的个数筛选条件为个数大于3的 表2
-- 3.将表2 做为子表筛选出 maker-- 1.
-- select maker,speed
-- from pc,product
-- where pc.model product.model;-- -- 2.
-- select maker,count(maker)
-- from (select maker,speed
-- from pc,product
-- where pc.model product.model) AS temp
-- group by maker having count(maker) 3;-- 3.select maker from (select maker,count(maker)from (select distinct speed,makerfrom pc,productwhere pc.model product.model) AS tempgroup by maker having count(maker) 3) as temp2;