sample code for read a 2nd record from last in flatfile how
can do?
Answer Posted / sunilkumar
First open the file in reverse order using OPEN command
OPEN FILE file-name REVERSE
Then read twice to get the 2nd last record.
| Is This Answer Correct ? | 0 Yes | 2 No |
Post New Answer View All Answers
how can i see junk values in dclgen or in hostvariable of comp ?
How do you reference the fixed block file formats from cobol programs
Differentiate cobol and cobol-ii. (Most of our programs are written in cobolii, so, it is good to know, how, this is different from cobol)?
What is static and dynamic call in cobol?
Name some of the examples of COBOl 11?
I have a File that has duplicate records. I need only those records that occur more than thrice.?
What is a scope terminator give example?
What are the different rules for performing sort operation?
example for sub strings ? and refernce modifications whit output pls
How to get the last record in vsam file in cluster? And how can you get the ksds file records into cobol program?
What is the difference between Call and a Link?
How many bytes S(8) comp field occupy and its maximum value?
What happens when we move a comp-3 field to an edited (say z (9). Zz-)?
here is my requirement A1 is alphanumeric with value 'A1B2C3D4' as defined below 05 A1 PIC X(8) VALUE IS 'A1B2C3D4' but i need to have A2,A3 as ABCD & 1234 repectively...... A2 = ABCD A3 = 1234 Can you please explain me what are the different ways to do it?
What is length is cobol?