Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

i have a file which contains duplicates ? my requirement is to
eliminate duplicates and these elminated duplicates should be
moved to another file can any code this using sort ?

Answer Posted / prabudha jain

//SORTXSUM DD DSN=datasetname,
// DISP=(NEW,CATLG,DELETE),UNIT=SYSDA,
// SPACE=(CYL,(1,4),RLSE),
// DCB=(RECFM=FBM,LERCL=80,BLKSIZE=800)
.
.
//SYSIN DD *
SORT FIELDS=(1,3,CH,A)
SUM FIELDS=NONE,XSUM
/*

1. SORT FIELDS=(1,3,CH,A) - Input file will be sorted
depending upon the key specified above 1,3,CH,A.

2. SUM FIELDS=NONE,XSUM - NONE means it will eliminate
duplicates.XSUM option will copy all records eliminated in
sort process will copy to another dataset defined in
SORTXSUM stelp

Is This Answer Correct ?    12 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to pass the parameter in parm using linkage section ? (syntax)?

1133


What do you understand by the term “keyword” with respect to jcl and what is the opposite of the term?

1143


How can the attributes of one sms dataset be copied to another dataset?

1421


What are the parameters that are used in creating a gdg?

1203


What statement marks the beginning of a job step; assigns a name to the step; identifies the program or catalogued or in-stream procedure to be executed in the step?

1100


We can use PASS with permanent datasets also. THEN Which is the condition in which we may use PASS (instead of KEEP) with permanent data sets, while there is no need to specify UNIT and VOL for them like temporary data sets (in cas we use KEEP for permanent data sets) ?

2228


I have a COBOL program that ACCEPTs some input data. How do you code the JCL statement for this?

1190


what are the various stages of job processing?

1279


What do you understand by jcl?

1047


What is the format of comment statement?

1202


how JCL works?

1259


What is one line to pass PARM from JCL to COBOL?

4953


I have a job called careerride and some steps in it as step1,step2. But I want to execute step2 before step1 ? How do I do that?

1396


What is the use of disp parameter?

1138


How do you access an uncatalogued dataset in a jcl?

1214