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

sample code for read a 2nd record from last in flatfile how
can do?

Answer Posted / nsingh

ADD SEQUENCE NUMBER

SORT FIELDS=COPY
OUTREC FIELDS = (1,80,SEQNUM,ZD,A)

NOW SORT SEQ NUM IN DESCENDING ORDER
SORT FIELDS=(81,4,ZD,D)

INCLUDE ONLY 2ND LAST REC
SORT FILEDS = COPY
INCLUDE COND = (81,4,ZD,EQ,0002')

REMOVE SEQ NUM FROM FILE & THIS REC IS SELECTED
SORT FIELDS =COPY
OUTREC FIELDS = (1,80)

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

if we display var1 then what will b displayed in below condition. 77 var1 pic s9(2) value -10. 77 var1 pic s9(2) value -11. " " " -12. " " " -13. -14 ... ... -19.

6594


Name some of the examples of COBOl 11?

3144


What are various search techniques in cobol? Explain.

1074


)If there are 10 steps in GDG, if I want to refer the step2 after step5 . what should I do?

2011


What are the different rules for performing sort operation?

1227


Explain sorting techniques in cobol program? Provide the sort file definition, the sort statement, its syntax and meaning

1099


How you can characterize tables in cobol?

1203


What are the access modes of START statement?

1273


What is static and dynamic call in cobol?

1070


There are 5 fields and 1000 records in a file. Unload it into an array. Write the syntax for declaration and how will you unload it.

1441


Write a program to enter and display the names of students in a class using the occurs clause.

1213


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

1196


How many bytes S(8) comp field occupy and its maximum value?

2144


What is the LINKAGE SECTION used in COBOL?

1531


How do u write test cases?

2070