Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
what is sortxsum?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
sandeep4u

New User


Joined: 12 Aug 2005
Posts: 32

PostPosted: Tue Jan 10, 2006 12:26 pm    Post subject: what is sortxsum?
Reply with quote

Hi,
What is sortxsum? where it is used n how to use it?please give example..


regards,

sandeep
Back to top
View user's profile Send private message

Gautam512

Active User


Joined: 05 Oct 2005
Posts: 309
Location: Vizag / US

PostPosted: Tue Jan 10, 2006 12:53 pm    Post subject: Re: what is sortxsum?
Reply with quote

Hi Sandeep,

sortxsum is generally used to retrieve the records that were suppressed due to duplicates.

In the JCL a DD statement SORTXSUM for the dataset to store the suppressed records due to duplicates and in the SYSIN XSUM should be used.

There is a inter-link between sortxsum and xsum.

Ex : SUM FIELDS=NONE,XSUM

Hope Iam clear,
Gau
Back to top
View user's profile Send private message
vinodmaanju

New User


Joined: 10 May 2005
Posts: 28
Location: Pune

PostPosted: Tue Jan 10, 2006 1:01 pm    Post subject:
Reply with quote

Hi,


Yes, I agree with Gautam.
Back to top
View user's profile Send private message
sandeep4u

New User


Joined: 12 Aug 2005
Posts: 32

PostPosted: Tue Jan 10, 2006 1:49 pm    Post subject: Re: what is sortxsum?
Reply with quote

Thanks Gautam.

Can you provide me a example or a document link so that i can clear it myself.
Back to top
View user's profile Send private message
nikyojin

New User


Joined: 05 Oct 2005
Posts: 94

PostPosted: Tue Jan 10, 2006 2:47 pm    Post subject: Re: what is sortxsum?
Reply with quote

Hi Sandeep4u,
Code:

//STEP002  EXEC PGM=SORT
//SYSPRINT DD SYSOUT=*
//SORTWK01 DD UNIT=WORK,SPACE=(TRK,(20,10),RLSE)
//SORTWK02 DD UNIT=WORK,SPACE=(TRK,(20,10),RLSE)
//SORTWK03 DD UNIT=WORK,SPACE=(TRK,(20,10),RLSE)
//SORTWK04 DD UNIT=WORK,SPACE=(TRK,(20,10),RLSE)
//SORTIN   DD DSN=ALM.TESTS.CV.AIDCATG.NIK,
//            DISP=SHR
//SORTOUT  DD DSN=ALM.TESTS.CV.AIDCATG.NIK1,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(TRK,(10,5),RLSE),
//            DCB=(RECFM=FB,LRECL=10,DSORG=PS)
//SORTXSUM DD DSN=ALM.TESTS.CV.AIDCATG.NIK2,
//            DISP=(NEW,CATLG,DELETE),
//            UNIT=SYSDA,
//            SPACE=(TRK,(10,5),RLSE),
//            DCB=(RECFM=FB,LRECL=10,DSORG=PS)
//SYSOUT   DD SYSOUT=*
//SYSIN    DD *
  SORT FIELDS=(1,7,CH,A)
  SUM FIELDS=NONE,XSUM
/*


The above JCL provided is an example of SortXsum.
The Iput file is sorted on the bytes 1----7 and the i/p rec is wriitten into the o/p file denoted by SORTOUT.
In SYSIN it is mentioned SUM FIELDS=NONE,XSUM,
1) None :- indicates there should be no duplicate in the O/p
2) XSUM :- indicates the duplicate record should be mentioned in the file corresponding to SORTXSUM ddname;

Hence if 1----7 characters is name field and if the name is repeated twice in the i/p file the first rec after sorting will be put in the o/p file and the second rec goes to Xsum file.
Do inform me if any further information is required....
Back to top
View user's profile Send private message
sandeep4u

New User


Joined: 12 Aug 2005
Posts: 32

PostPosted: Tue Jan 10, 2006 3:54 pm    Post subject: Re: what is sortxsum?
Reply with quote

thanks gautam.


It seem really very helpful...

thanks a lot


regards,

sandeep
Back to top
View user's profile Send private message
nikyojin

New User


Joined: 05 Oct 2005
Posts: 94

PostPosted: Tue Jan 10, 2006 4:33 pm    Post subject: Re: what is sortxsum?
Reply with quote

Not Gautam....This is Nikhil over here....Do get back if u face any problems
Back to top
View user's profile Send private message
mjake

New User


Joined: 15 Feb 2006
Posts: 2

PostPosted: Wed Feb 15, 2006 10:34 pm    Post subject: Re: what is sortxsum?
Reply with quote

In the example given (JCL), is there a way to OMIT or SKIPREC some records from being processed in the XSUM?

Example:
Input file contains both Issue and cancel records.
(I)ssue records may be duplicated.
(C)ancel records that are duplicated cause an abend (long story).
I need to be able to exclude the Issue records from being sorted "out".

//SYSIN DD *
SORT FIELDS=(2,28,CH,A,1,1,CH,D),EQUALS
SUM FIELDS=NONE,XSUM


Any help will be greatly appreciated.

Thanks,
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts find matching entries from SORTOUT fo... ramsri JCL & VSAM 6 Thu Dec 12, 2013 4:33 pm
No new posts Change the layout for SORTXSUM file bodatrinadh JCL & VSAM 8 Thu Dec 09, 2010 2:20 pm
No new posts In sorting what is the use of XSUM/SO... madlui56 JCL & VSAM 4 Wed Jul 18, 2007 12:28 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us