HOW TO MOVE REDEFINES CLAUSE FROM INPUT TO OUTPUT ?
Answer / adarsha
01 ws-misc-vars.
05 system-date pic x(06) value spaces.
05 system-date-rede redefines system-date
10 system-dt-yy pic x(02) value spaces.
10 system-dt-mm pic x(02) value spaces.
10 system-dt-dd pic x(02) value spaces.
01 ws-rep-dt-frmt pic x(06) value space.
.
.
.
procedure division.
move system-date to ws-rep-dt-frmt.
*** when you want any particular variable to be recevied or
stored in a particular format you can redefine them in the
way you want.. here system-date-rede has the same value as
system-date !
| Is This Answer Correct ? | 1 Yes | 0 No |
Explain what you understand by passing by value.
a. Can the OPTIONAL clause in COBOL only be coded for input files? b. If it is coded for files opened in OUTPUT, I-O or EXTEND mode, will it give a compilation error? c. If there are no compilation errors and if such files are not coded in the JCL, will the OPEN statement run fine when these files are opened? d. How will a WRITE statement work for the above files?
what is the advantage of using redefines instead of delaring the variables ?
HOw can I get the negative sign while deduct high value from low value
What is the Purpose of POINTER Phrase in STRING command
what is s000 u4087 error? please give the all error codes in cobol,jcl.
What is the Purpose of POINTER Phrase in STRING command in COBOL?
COMP field occupy ?
When the working storage variables get allocated? a.At Compile time b.At starting of the run time c.At end of the run time. d.None of these
what will happen if pass values more than 100 using PARM parameter?
how you will define variables length in cobol.
) what is the difference between AID and HANDLE AID?