Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a scenario wherein, I have Rule_Set, ID_no, Sys_Key.
Rule_Set | ID_no | Sys_Key |
---|---|---|
Rule1 | 1234 | 1A |
Rule1 | 2345 | 1B |
Rule2 | 3456 | 1A |
Rule3 | 4567 | 1C |
There is another Table (a Mapping Load) which has Certain Rule_Set and Sys_Key Defined. like;
Rule_Set | Sys_Key |
---|---|
Rule1 | 1A |
Rule2 | 1A |
The requirement is , the ID_no should be fetched , for the Rules mentioned in the Mapping Load Table for the Sys_Key, If the rule is not mentioned, then all the Sys_Key should be fetched. thus the result should be;
Rule_Set | ID_no | Sys_Key |
---|---|---|
Rule1 | 1234 | 1A |
Rule2 | 3456 | 1A |
Rule3 | 4567 | 1C |
The actual app has a complex data, hence Association is not the solution.
I was thinking of creating the Flag , but it somehow is feting the 'ID_no 3456' in this case for the condition where I am trying to get the rules not mentioned in the Mapping Table.
Appreciate any help!
Thanks !
PriyankaSR have tried the script I suggested?
Hi Kush,
Appreciate your reply.
Yes, this way I am able to get the Rules mentioned ine Mapping Table by Inner Join.
But somehow didn't get the part to fetch all other cases .
To be specific the Condition ' where not Exists(Rule_Set)', how can I use it on the Original Table as mentioned ?
Can you pls explain this part ?
Thanks !!
If you reach your desire goal, close this thread by choosing correct or helpful to learn others.