DFSort Merge clarification



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

DFSort Merge clarification

Postby gowthamgyaa » Fri Oct 05, 2012 6:16 pm

Hi everyone,
The below merge conditions using JCL statements shows me an error, I tried it but am unable to solve with that, I need your experience hands in solving this,


//JOB STATEMNT
//STEP1 EXEC PGM=SORT
//SYSPRINT DD SYSOUT=*
//SORTOUT DD SYSOUT=*
//SORTIN1 DD DSN=******.FINANCE.EMP,DISP=SHR
//SORTOUT DD DSN=*****.BACKUP.EMP,DISP=MOD
//SYSIN DD *
MERGE FIELDS=(5,2,CH,D)
/*
//


RECORDS IN FINANCE.EMP
001 cse 1005
002 ece 1111
008 mec 1007
014 cse 1222
077 aaa 1453
088 sss 1000
015 mmm 1005

RECORDS IN BACKUP.EMP
001 cse 1005
002 ece 1111
008 mec 1007
077 aaa 1453
015 mmm 1005
024 UTV 1017
028 MTV 1027
044 ATV 1113
012 ZZZ 1234

Kindly guide me what may be wrong in this.


Kind regards
gyaa
gowthamgyaa
 
Posts: 101
Joined: Wed Sep 05, 2012 11:18 pm
Has thanked: 67 times
Been thanked: 0 time

Re: DFSort Merge clarification

Postby enrico-sorichetti » Fri Oct 05, 2012 6:50 pm

The below merge conditions using JCL statements shows me an error,


Kindly guide me what may be wrong in this.


instead of having everybody guessing why don' You start by telling us what error You received ...

most probably if You look at Your input You will find out that it is not in sequence as required by a MERGE application
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 3006
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 165 times

Re: DFSort Merge clarification

Postby gowthamgyaa » Fri Oct 05, 2012 6:56 pm

@enrico,
Thank you very much for the quick guidance.


Kind regard's
gyaa
gowthamgyaa
 
Posts: 101
Joined: Wed Sep 05, 2012 11:18 pm
Has thanked: 67 times
Been thanked: 0 time

Re: DFSort Merge clarification

Postby BillyBoyo » Fri Oct 05, 2012 6:57 pm

With the sample you show, Enrico has your answer. For MERGE, the data has to be in sequence on the key. If data is not in sequence, you SORT.

These users thanked the author BillyBoyo for the post:
gowthamgyaa (Fri Oct 05, 2012 7:13 pm)
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 265 times

Re: DFSort Merge clarification

Postby NicC » Fri Oct 05, 2012 7:08 pm

you also have 2 sortout ddnames - you can only have one. (You can have more than one but all but one will be ignored - I will leave it to you to research which one will be used). An why do you have DISP=MOD on your SORTOUT? Do you really want to add data to what is already in that dataset?

The sort manual has a whole chapter devoted to the JCL requirements that you need - read it, along with the JCL manual.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic

These users thanked the author NicC for the post:
gowthamgyaa (Fri Oct 05, 2012 7:13 pm)
NicC
Global moderator
 
Posts: 3025
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisies (almost)
Has thanked: 4 times
Been thanked: 136 times

Re: DFSort Merge clarification

Postby skolusu » Fri Oct 05, 2012 8:49 pm

gowthamgyaa,

You need to show us the error message you got or you can look it up your self which is pretty much self explanatory. Here is the manual for checking the error messages

http://publibz.boulder.ibm.com/cgi-bin/ ... /CCONTENTS
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

These users thanked the author skolusu for the post:
gowthamgyaa (Fri Oct 05, 2012 10:13 pm)
skolusu
 
Posts: 586
Joined: Wed Apr 02, 2008 10:38 pm
Has thanked: 0 time
Been thanked: 39 times


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post