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


Please Help Members By Posting Answers For Below Questions

What is the Purpose of Pointer in the string?

643


what are decleratives in cobol?

1827


if we have " ibm mainframe ",in that how to remove first and last leading space eg:"ibm mainframe" like that the answer we need

859


How did the release of cobol/370 version 1.3 improve the performance of release 1.1?

645


how do you define single dimensional array and multidimensional array in your cobol?

678






What rules are followed by the search verb.

638


Which Search verb is equivalent to PERFORM…VARYING?

687


How arrays can be defined in COBOL?

663


What are the different rules for performing sort operation?

763


State the various causes of s0c1, s0c5 and s0c7.

665


input= ,,,, mainframe training ,,, hyderabad .... location.... output1=$ mainframe training in hyderabad location$ output2=**** mainframe training in hyderabad location ****. In this pgn when we give input considering the spaces the output is displayed in this format.Like in the place of ,,,, $ should be displayed likewise.So please helpmeout.

1783


INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?

423


Give some examples of command terminators?

759


What is rmode(24)

681


what is difference between cobol and cobol/400

21567