# case 사용
select count(*) as FISH_COUNT, max(LENGTH) as MAX_LENGTH, FISH_TYPE
from FISH_INFO
group by FISH_TYPE
having avg(case when LENGTH is null then 10 else LENGTH end) >= 33
order by FISH_TYPE
# ifnull() 사용
select count(*) as FISH_COUNT, max(LENGTH) as MAX_LENGTH, FISH_TYPE
from FISH_INFO
group by FISH_TYPE
having avg(ifnull(LENGTH,10)) >= 33
order by FISH_TYPE