According to given sample data there is "Type" which is common in both table
Select B.PERS, T.DESC from BaseTable B right outer Join Testtable T on ( T.type is null or B.Type=T.type or B.Type is null)and T.Grp = 'G1' where T.DESC<>'' order by B.PERS asc
Select B.PERS, T.DESC
from BaseTable B
right outer Join Testtable T
on ( T.type is null or B.Type=T.type or B.Type is null)
and T.Grp = 'G1'
where T.DESC<>''
order by B.PERS asc