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
Are you comfortable in cobol or jcl?
What are the different rules of SORT operation?
Name the divisions, which are available in a cobol program?
State the various causes of s0c1, s0c5 and s0c7.
Our issue is there seems to be a disconnect, or no link, between our SELECT statement and our SD. We had SELECT SORT-FILE and SELECT SORT-FILE ASSIGN TO SORTWRK. ASSIGN TO SORTWRK1 SORTWRK2 SORTWRK3 SORTWRK4. with SD SORT_FILE RECORD CONTAINS 7833 CHARACTERS. In either case, at run time, the system ignored our SORTWRK# DD statements and allocated 16 sort works with the SORTWK## naming convention. Any ideas why the system does not recognize the connection? We do not even need the SORTWRK DD statements. Thanks
How do define dynamic array in cobol. how do you define single dimensional array and multidimensional array in your cobol?
) How do u handle errors in BMS macro?
Can you please let me know the centre name of INS certification in Kolkata.
What are 77 levels used for?
1.Is it possible to move the data from 99.99 to 99v99? 2.What is the CICS-vsam Compilation process? 3.In My GDG 5 generation will be there GDG3 got an abend what will happen? 4.In my GDG first generation is +1 And I want to add the new generation what will happen previous generation? 5.How can you give the PIC clause below conditions A). s9 (reddy), B). s9 (5) occurs 5 times? 6.How override the proc from a particular step? and what is symbolic and override Procs?
how do you reference the printer file formats from cobol programs
Can we change the password using ALTER? anyone tried and changed?
Can a Search can be done on a table with or without Index?
Why would you use find and get rather than to obtain?
If you are current on the owner of a set, what is the difference between an obtain next and obtain first? Actually in which topic will we use dis???Plz explain it clearly