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...

how to write a jcl prog to copy alternate recs from ps1 to
another ps2,suppose ps1 having 10 recs?

Answer Posted / vaneesh khurana

To do so we require OUTFIL and SPLIT option of DFSORT.

//STEPNAME EXEC PGM=SORT
//SORTIN DD DSN=SORTIN.INPUT.FILE.TO.SPLIT,DISP=SHR
//PS1 DD DSN=PS1.FILE,DISP=SHR
//PS2 DD DSN=PS2.FILE,DISP=SHR
//SYSIN DD *
OUTFIL FNAMES=(PS1,PS2),SPLIT
/*

This will write 1st, 3rd,5th ....record in the PS1 and
2nd,4th,6th ....record in ps2 file.

Is This Answer Correct ?    14 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the function of //jcllib statement?

1265


Is it possible to left uncode disp?

1138


I have a cobol db2 program(PGM A) where other program (PGM B) will call this program and passes some 50 fields data to PGM A. PGM A has some layout in which it receives the data from PGM B. And this layout has been copied in the linkage section pf PGM A. After getting the data, PGM A writes the data in a flat file in the same layout which it receives from PGM B. PGM B is a simple COBOL pgm. Please provide a JCL to run these programs.

2293


Explain the purpose of the dd keylen parameter?

1098


IIN APITUDE THEY GAVE ONLY 10 QUESTIONS.. THEY ARE SIMPLE ONE FROM NUMBER SERIES,BOATS,TIME & DISTANCE,PROFIT &LOSS,FIND OUT THE NUMBER ? 9 25 4 36 81 64 49 AND surveillance SPELLINGS E.T.C

2116


What are the rules employed while naming the steps in a job?

1089


What are the parameter we cannot use in procedure? How many instream we can write in single jcl?

999


What is the motivation behind coding class parameter in job statement?

1130


Is condition checking possible in jcl?

1144


Explain the function of job statement in jcl?

1127


What are the jcl procedures?

1058


Many jcl statements contain specific values designed to direct and control the execution of the statement. What are these fields called?

1163


What is the purpose of dd dummy statement?

1402


What statement can be used to send data to another mvs jes3 node?

1567


what happens in conversion stage in job processing?

1168