Krazykoolrohit it's almost this.Krazykoolrohit wrote: How does that affect the calculations?? you are doing lookup matching all your columns in lookup file with the main file?
![Smile :)](./images/smilies/icon_smile.gif)
main input = LINK_001
main_id
dt_record
lookup input = LINK_002
lookup_id
lookup_desc
dt_start
dt_end
rule: Only load the records where main_id = lookup_id
and dt_record between dt_start and dt_end.
I need to match:
LINK_001.main_id = LINK_002.lookup_id
LINK_002.dt_start <= LINK_001.dt_record
LINK_001.dt_record <= LINK_001.dt_end
The objective here is get the correct description (LINK_002.lookup_desc) when this description was valid.
For example: To the same ID(LINK_002.lookup_id) I can have one description for a month and other description to the next month. Something like
lookup_id lookup_desc dt_start _________ dt_end
1_______ AAA _______ 01/01/2005_______ 10/07/2005
1_______ BBB _______ 10/08/2005_______ 01/10/2005
1_______ CCC_______ 02/10/2005_______ 10/01/2006
Well, for the ID = 1 the correct description in 10/09/2005 is "BBB" but in 03/11/2005 the correct description is "CCC".
Thanks,
Fernando