select case
when t.OWNER = 'SYS' then
'AA'
when t.OWNER = 'HH7YX' then
'BB'
else
'CC'
end a,
count(1)
from dba_objects t
group by case
when t.OWNER = 'SYS' then
'AA'
when t.OWNER = 'HH7YX' then
'BB'
else
'CC'
end