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.
あるテーブルの主キー フィールド値 (ID など) が MySQL の別の関連テーブルで使用されていることを確認するにはどうすればよいですか?
私を助けてください。
データベースの構造を知っている必要があります。その後、あなたは次のようなことをすることができます
select * from your_table where id in ( select id from ref_table1 union select id from ref_table2 union select id from ref_table3 )