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

have in 100 records in a file i want to move only matched
records to one output_file1 and nonmathed records are
moved to another output_file2 ... any one can provide
logic code

Answer Posted / ananth

Use Syncsort or Dfsort for this.

//S001 EXEC PGM=SORT
//SORTIN DD DSN=inputfile,DISP=SHR
//SORTOF01 DD DSN=dsn.match,DISP=(NEW,CATLG)
//SORTOF02 DD DSN=dsn.unmatch,DISP=(NEW,CATLG)
//SYSOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=(1,5,CH,A)
OUTFIL FNAMES=01,INCLUDE=(1,5,CH,EQ,C'A1000')->for match
OUTFIL FNAMES=02,INCLUDE=(1,5,CH,NE,C'A1000')->for nonmatch
/*

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a report item?

1148


What is perform what is varying?

1182


how do you reference the ksds vsam file formats from cobol programs

1199


which is Best IBM Mainframe Training and Placement Institute in Ameerpet Hyderabad

1506


What is a SSRANGE and NOSSRANGE?

1476


How do get the result of your program directly on your pc?

2350


What is the difference between perform … with test after and perform … with test before?

1462


how do you reference the variable block file formats from cobol programs

1264


Differentiate between structured cobol programming and object-oriented cobol programming.

1161


What is the difference between a binary search and a sequential search what are the pertinent cobol?

1146


How arrays can be defined in COBOL?

1225


What is the Purpose of Pointer in the string?

1083


Which division and paragraphs are mandatory for a COBOL program?

1285


How to know whether the module is dynamical or statistical?

1148


How do you differentiate between cobol and cobol-ii?

1215