を提案してください内部結合を試みたが、役に立たない
でした助けになりませんか?
create table t_col (a varchar2(1),b varchar2(1),c varchar2(1));
insert into t_col (a,b,c) values('x','y','z');
insert into t_col (a,b,c) values('y','x','z');
select distinct col.c
from t_col col
join t_col col2 on Col.a = Col2.b and Col.b = col2.a and Col.c = Col2.c;
または
select distinct col.c
from t_col col
where exists (select null
from t_col col2
where Col.a = Col2.b
and Col.b = col2.a
and Col.c = Col2.c);
または我々はヌルに
select distinct col.c
from t_col col
where exists (select null
from t_col col2
where decode(Col.a,Col2.b,1,0) = 1
and decode(Col.b,col2.a,1,0) = 1
and decode(Col.c,Col2.c,1,0) = 1);
私は全くないんだけどあなたがしたいことを確かめてください。 col.cの値が特定の値であるcol.aとcol.bのすべての情報が必要な場合は、SELECT * FROMテーブルWHERE col.c = zを使用します。 INNER JOINはmltupleテーブル間でのみ動作します –