Now we are in the phase of Supra to DB2 Migration, need to get more information how to set up the foreign keys on Variable table along with sequence number to pull the distinct required records out of Variable table using Master.

Example
Master table has
AAAA BBBB CCCC

Variable has
AAAAA 0001
AAAAA 0002
AAAAA 0003
BBBBB 0001

Now How will my program fetch the...