Overlay one file using the field from input(another) file



IBM's flagship sort product DFSORT for sorting, merging, copying, data manipulation and reporting. Includes ICETOOL and ICEGENER

Overlay one file using the field from input(another) file

Postby sethukutty » Thu May 11, 2017 12:31 am

I need help on overlaying the OUT file using IN file. IN file has the actual date but few months are missing. I want to fill the right date from IN file into OUT file.

IN File:

20170223
20170324
20170425
20170524
20170623


OUT File has already the date format as follows:

20170101
20170201
20170301
20170401
20170501
20170601
20170701
20170801
20170901
20171001
20171101
20171201


New OUT File should be as follows:

20170101
20170223
20170324
20170425
20170524
20170623
20170701
20170801
20170901
20171001
20171101
20171201


Thanks
Ram

CODE' d
sethukutty
 
Posts: 10
Joined: Fri Jun 20, 2014 6:21 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Overlay one file using the field from input(another) file

 

Re: Overlay one file using the field from input(another) fil

Postby NicC » Thu May 11, 2017 12:41 am

From that description and with the data presented it looks like a simple MERGE operation.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2681
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 102 times

Re: Overlay one file using the field from input(another) fil

Postby sethukutty » Thu May 11, 2017 12:44 am

The dates are in different column.
sethukutty
 
Posts: 10
Joined: Fri Jun 20, 2014 6:21 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Overlay one file using the field from input(another) fil

Postby sethukutty » Thu May 11, 2017 1:07 am

Dates starts from col 17 in IN file
Dates starts from col 4 in OUT file
sethukutty
 
Posts: 10
Joined: Fri Jun 20, 2014 6:21 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Overlay one file using the field from input(another) fil

Postby sethukutty » Thu May 11, 2017 2:48 am

Sorry. Let me give more information:

IN File has the following data (Dates starts from col 17 in IN file):

XXXXXXXXXXXXXXXX20170223
XXXXXXXXXXXXXXXX20170324
XXXXXXXXXXXXXXXX20170425
XXXXXXXXXXXXXXXX20170524
XXXXXXXXXXXXXXXX20170623
 

OUT File has already the following data (Dates starts from col 4 in OUT file):

XXX20170101
XXX20170201
XXX20170301
XXX20170401
XXX20170501
XXX20170601
XXX20170701
XXX20170801
XXX20170901
XXX20171001
XXX20171101
XXX20171201


I want the OUT file to be

XXX20170101
XXX20170223
XXX20170324
XXX20170425
XXX20170524
XXX20170623
XXX20170701
XXX20170801
XXX20170901
XXX20171001
XXX20171101
XXX20171201


CODED' d AGAIN
sethukutty
 
Posts: 10
Joined: Fri Jun 20, 2014 6:21 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Overlay one file using the field from input(another) fil

Postby NicC » Thu May 11, 2017 2:54 pm

And you are not using the code tags because...?
And they are data sets not "files".
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2681
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 102 times

Re: Overlay one file using the field from input(another) fil

Postby sethukutty » Thu May 11, 2017 7:07 pm

I have used Join keys and made it work. Thanks.
sethukutty
 
Posts: 10
Joined: Fri Jun 20, 2014 6:21 pm
Has thanked: 0 time
Been thanked: 0 time


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post