sorry but it is NOT working! I checked twice.
select t.SONUC,count(*) as TOPLAM FROM
(select
CASE
when s.sonuc ='E' then 'E'
when s.sonuc ='A' then 'GELMEYEN'
END ,
CASE
when s.deep < 1 then 'MDL-0.99'
when s.deep between 1 and 4.9 then '1.0-4.9'
when s.deep between 5.0 and 9.9 then '5.0-9.9'
when s.deep between 10.0 and 14.9 then '10.0-14.9'
when s.deep between 15.0 and 19.9 then '15.0-19.9'
when s.deep between 20.0 and 29.9 then '20.0-29.9'
when s.deep > 30.0 then '>30.0'
when s.deep > 0.1 then 'MDL'
END as SONUC
from
(dzmt.sonuc s
LEFT OUTER JOIN dzmt.dagitim d ON s.dagitimid = d.id),dzmt.priyotlar p
where
d.periyodid = p.id and
p.yil = 2007) as t
group by SONUC
Because of group by SONUC , it only gets the second CASE statement part. How can i get all of the results from both case statements in one column?