How to remove the spaces at end of each record in the output file Via COBOL program? note: The file has a VB length ----TRY
Answer / Sachin Kumar Mourya
In COBOL, you can use the TRIM function or the MOVE statement with space-suppressed processing (SSP) to remove trailing spaces from records. Here is an example using SSP:nn 01 Record PIC X(VB).n PROCEDURE DIVISION.n MOVE SPACE TO Record.n ACCEPT Record.n DISPLAY TRIM(Space-Suppressed Record).
| Is This Answer Correct ? | 0 Yes | 0 No |
Explain about LMINIT - generate a data ID for a data set
when GDG version number get changed ? bcz always Generations only increasing.
What are the rules employed while naming the steps in a job?
How can I override a dsn that is contained in a proc called by another proc? I need to do the override in the calling JCL.
A file has dta in S9(09) COMP format. How do I move the data into a character field X(10)?
How many types of parameters are used in JCL and what are mandatory parameters of JOB statement.
Explain in DD statement what is the use of DCB parameter?
which parameter is used to check the syntax of a jcl without executing it?
how to run JCL thru COBOL.
A maximum of 100 chars can be passed to Cobol through Parm in JCL, If we want to pass more than 100 Chars how we can do it ?
AM HAVING A FILE WHICH CONTAIN 12 DATS OUT OF WHICH 4 ARE DUPLICATES HOW TO REMOVE THE DUPLICATE FILES IN JCL? CAN I GET THE PROGRAM FOR THIS
have in 100 records in a file i want to read first 3 records and skip next 3 records and agan i want to read 3 records and again i want to skip 3 records... run a loop from record one to 10 evaluate i/3 if comes even then skip else write to output file