-
query based on multiple matches
hey, i'm new to oracle and i'm trying to write a query that will match data objects based on classifications to a module.
Data_ID Classification_ID
1 83
1 56
1 102
2 102
2 23
3 4
Module_ID Classification_ID
10 83
10 56
5 102
8 102
8 26
8 4
All columns are FK that point to other tables.
Given the following two tables, is it possible to do a query that will get the data_id from the first table (table A) if and that data_id has at least the same classification_ids as one module_id (Table B).
EX: module_id 10 has classification_ids 83,56 so data_id 1 would be returned and as well module_id 5 has classification_id 102 so it would be returned, but module_id 8 having classification_ids 102,26,4 has no matching data_id so nothing would be returned for that.
Any help is appreciated.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|