Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
このコードを変更して、結果に列 A と D の両方を表示するにはどうすればよいですか?
SQL> SELECT A FROM R WHERE EXISTS (SELECT D FROM S WHERE S.D=R.A AND S.C=R.B);
結果:
A ---------- 1
Select A, D From R Inner Join S On S.D = R.A And S.C = R.B
SELECT R.A, S.D FROM R INNER JOIN S ON S.D = R.A AND S.C = R.B