Aselect * from A right outer join B on A.id=B.id where A.id is null;
Bselect * from A left outer join B on A.id=B.id where B.id is null;
Cselect * from A right outer join B on A.id=B.id where A.id is not null;
Dselect * from A left outer join B on A.id=B.id where B.id is not null;