How to remove the spaces at end of each record in the
output file Via COBOL program?
note: The file has a VB length
Answer Posted / mvramesh
I will explain this with an example. Lest assume the Maximum record length for VB file is 4000.
For every record you write, Move the actual record length value to RECORD-LENGTH, this would trim off the entire record beyond that length. If the data is populated only till 3000 bytes, move 3000 to RECORD-LENGTH which would trim off the last 1000 bytes.
I hope i answered your question.
| Is This Answer Correct ? | 2 Yes | 4 No |
Post New Answer View All Answers
How do we get current date from system with century in COBOL?
1.give the details about WHEN OTHER. 2. how many form are available in evaluate.
What are different data types in cobol?
how do you reference the printer file formats from cobol programs
What is the difference between Call and a Link?
IF I mention stop run in CICS what happens?
What is the compute verb? How is it used?
What rules are followed by the search verb.
What is the local-storage section?
how to refer the data field?
How to read the 2nd last record of a VSAM file? (The file size is huge and we don't know the key)
What is the default value(s) for an initialize? What keyword will allow for an override of the default?
I have File 1 occurs 5 times with Employee-ID,Employee-Name,Employee-Dept (EEE and MECH). I have File 2 occurs 10 times with Employee-ID,Employee-Name,Employee-Dept (EEE,CIVIL,CHEMICAL and MECH). In FIle 1 and FIle 2 , for matching Employee-DEPT (Only MECH) , we need to move entire records from file1 to file 2. We should not use 2D array. Your help is needed here.
Explain the configuration section of a cobol program with examples of syntax.
can you please let me know if there is any walkins for COBOL/PLI/DB2/IMS/JCL in pune other than IBM and ITC infotech