copy already sorted data



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

copy already sorted data

Postby jnkarthik » Sun Nov 21, 2010 5:29 pm

Hi,
I have two input files as below
In1 Dataset name 'MY.DATA1'
Var1 DATA1
----- --------
XYZ 20000
abc 25000
123 30000

in2 Dataset name 'MY.DATA2'
VAR2 DATA2 DATA3 DATA4 DATA5
------ ------- ------- ------- --------
XYZ 05000 a b c
abc 17000 a
123 10000 X

My Output should be as below
XYZ 20000 a b c
abc 25000 a
123 30000 X

My DATA1 in input file is update data which i need to update in INPUT2 rest of input2 should be same.
Can it be achieved in DFSORT?
Can it be updated in 'MY.DATA2' dataset means it will be my input and output dataset as well, can this be done?
jnkarthik
 
Posts: 14
Joined: Wed Oct 20, 2010 3:45 pm
Has thanked: 0 time
Been thanked: 0 time

Re: copy already sorted data

Postby dick scherrer » Sun Nov 21, 2010 10:34 pm

Hello,

Do not overwrite input data during a process (sort or otherwise). If there is a problem, the input data is corrupted/destroyed. Well managed environments will not allow this.

Process the 2 input files and write a new output file.

Yes, this can be done using DFSORT. Suggest you review topics that JOIN 2 files. There are examples in the forum.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: copy already sorted data

Postby Frank Yaeger » Tue Nov 23, 2010 12:48 am

jnkarthik,

What is the RECFM and LRECL of each file?

What is the starting position, length and format of each relevant field?
Frank Yaeger - DFSORT Development Team (IBM) - yaeger@us.ibm.com
Specialties: JOINKEYS, FINDREP, WHEN=GROUP, ICETOOL, Symbols, Migration
=> DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort
User avatar
Frank Yaeger
Global moderator
 
Posts: 1079
Joined: Sat Jun 09, 2007 8:44 pm
Has thanked: 0 time
Been thanked: 15 times


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post