I have a source program compiled with Cobol-2. The output
file has a record length of 100 defined in the program but
a record of 60 bytes getting written into it. i.e. The rest
of 40 bytes I am not Writing anything. But it by default
puts some values into the last 40 bytes. However it does
not impact anything. But when Compiled the module with
Enterprise Cobol the last 40 bytes were spaces as fillers.
Can anyone explain?
Answer Posted / ram.g
hi
Before writing into the output file, just explicitly give
move spaces to rest of fields..
eg: ww-filler pic x(40) value spaces.
move ww-filler to ww-out-rec(61:40)
write ww-out-rec.
i hope the above code will resovle your problem.
Happy coding,
Ram.G
Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
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
how to move the records from file to array table. give with code example
what is difference between cobol and cobol/400
How did the release of cobol/370 version 1.3 improve the performance of release 1.1?
What is redefines clause in COBOL?
What rules are followed by the search verb.
Is it possible that the redefines clause has different picture clauses compared to the one it redefined?
Write a cobol program making use of the redefine clause.
How do get the result of your program directly on your pc?
Why is it necessary that file needs to be opened in I-O mode for REWRITE?
i made it to stage 3 of an interview process wednessday they will quiz my knowledge again face to face for an analyst role recruiter said it will be based on Business requirements system is cobol and good ideas what they might ask etc
Have you used comp and comp-3 in your project? And how?
i want a program using by if, evaluate , string, unstring, perform, occurs?
Write a program that uses move corresponding.
What are all the divisions of a COBOL program?