MySQL與Oracle 按年齡段分組查詢 |
發(fā)布時(shí)間: 2012/8/17 18:01:03 |
MySQL與Oracle 按年齡段分組查詢: select nnd, count(*) from(
when em_age>=31 and em_age<=40 then '31-40' else 'other' end as nnd,em_sex from hr_employee ) hr_employee group by nnd 本文出自:億恩科技【1tcdy.com】
when em_age>=31 and em_age<=40 then '31-40' else 'other' end as nnd,em_sex from hr_employee ) hr_employee group by nnd 本文出自:億恩科技【www.enidc.com】 --> 服務(wù)器租用/服務(wù)器托管中國(guó)五強(qiáng)!虛擬主機(jī)域名注冊(cè)頂級(jí)提供商!15年品質(zhì)保障!--億恩科技[ENKJ.COM] |