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.
すべての子会社と契約を結んだクライアントを選択するにはどうすればよいですか?
R2 UID | Subsidiary 1 | 1 1 | 2 1 | 3 2 | 1 2 | 2 3 | 1 3 | 1
この質問について教えていただけますか?
このようなもの:
select u_r2.uid from (select uid , count(distinct subsidiary) as u_subs from r2 group by uid ) u_r2 , (select count (distinct subsidiary) as tot_subs from r2) sub_r2 where sub_r2.tot_subs = u_r2.u_subs;