2013-08-13 4 views

ответ

2
select num 
from your_table 
where num not in 
(
    select num 
    from your_table 
    where type = 'B' 
) 
+0

Это работа, спасибо. – nametal

0

Попробуйте использовать not exists ниже

select * 
from tab t 
where t.type = 'A' 
and not exists 
(
    select 1 
    from tab t1 
    where t1.type = 'B' 
    and t1.num=t.num 

) 
Смежные вопросы