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 read the last 100 records from a COBOL file. The file
contains N number of records.

Answer Posted / heeraj r

Pls post the correct question. I am not sure what you mean
by COBOL file, is it PS or VSAM or Tape etc etc? If you
want last 100 records of a file use below SORT JCL, and if
required that output file can be read in your COBOL.

//S1 EXEC
PGM=ICETOOL
//TOOLMSG DD
SYSOUT=*
//DFSMSG DD
SYSOUT=*
//IN DD DSN=... input
file
//OUT DD DSN=... output file
//TOOLIN DD
*
SUBSET FROM(IN) TO(OUT) KEEP INPUT LAST(100)
/*

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

System Testing for Mainframe Developers What is System Testing? integration testing ? what's the procedure ..

2087


INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?

869


In COBOL programming, what is PERFORM? What is VARYING?

1156


What happens when we move a comp-3 field to an edited (say z (9). Zz-)?

1414


i have 10 names in an array and my name is one of them also array is not in sorted order i need to display my name using index how will i do this

1543


Give some examples of command terminators?

1268


Name some of the examples of COBOl 11?

3148


What is perform what is varying?

1187


How to get the last record in vsam file in cluster? And how can you get the ksds file records into cobol program?

1180


What is the difference between structured cobol programming and object alternativelyiented cobol?

1256


What guidelines should be followed to write a structured cobol prgm?

1161


What are the different types of condition in cobol and write their forms.

1119


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

2352


explain sorting techniques in cobol program?

1209


What is the local-storage section?

1156