I had 100 records and i want to execute last three records by
using cobol programming?what will be coding?
Answers were Sorted based on User's Feedback
Answer / atul
Using Short card you can write the last 3 records.
Short card as :
SORT FIELDS=COPY SKIPREC=97 STOPAFT=03
It will copy the last three records and put it in a file.
Cobol program can use this file containing records.
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / sandip
In cobol apply counter while reading file if counter reach at 97 start writing record to another file.
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / harsha
Read file sequentially and load it in table. keep check on
the number of ocurances(i.e. number of records).
Once the table is fully loaded, you know the total
occurances. Say it is X. Now read the table with occurance
X-3
| Is This Answer Correct ? | 2 Yes | 2 No |
Difference between ps, esds
when COMP-3 is preferrable?
what if any ,is the syntex error in the following piece of code 01 B PIC A(7) 02 C PIC 9(4) ........ IF(B NUMERIC) ADD 10 TO C a.the condition in the if statement is wrong b.noting is wrong c.because C is initialised.ADD 10 TO C is wrong d.both B and C shoud have same size.
What is the difference between binary search and sequential search?
Where the Plan is located in CICS-DB2
What are various search techniques in cobol? Explain.
Write a program to concert an Indexed file into Sequential file?
how do you reference the esds vsam file formats from cobol programs
How to code fscode 10 in cobol program? Where yoy code in your pgm?give ans for the question.
what happens if we dont close cursor in db2-cobol pgm?
how to transfer the file from pc to mainframe??
When would you use in-line perform?