77 a pic x(4) value '1234' -----> instead of this 'abcd'
77 b pic 9(4) value zeros.
move a to b
what is the answers for both cases?
IS it possible? Give me elementary move rules briefly......
Answer Posted / satish kumar
hello all, yes it is possible to move alphanumeric to
numeric but not numeric to alphanumeric.if we are moving
alphanumeric character "abcd" to numeric. The compiler
accepts the first three characters as same and the remaining
last character it takes ascii value/code of last character 'd'.
pgm1: 77 a pic x(4) value "abcd".
77 b pic 9(4) value zeros.
move a to b.
o/p: abc4
pgm2: 77 a pic 9(4) value 1234.
77 b pic x(4).
move a to b.
o/p: 1234
in this case the compiler can move the numeric values to
alphanumeric directly.
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
Can we change the password using ALTER? anyone tried and changed?
Write the code implementing the perform … varying.
Describe the cobol database components?
what is difference bt COND, REGION & TIME parameters at JOB & EXEC. give an exp.
How to know whether the module is dynamical or statistical?
How do you reference the following file formats from cobol programs?
what happens if parmparameter passes zero bytes to the program
What are various search techniques in cobol? Explain.
How to get the last record in vsam file in cluster? And how can you get the kids file records into your cobol program?
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.
How to get the last record in vsam file in cluster? And how can you get the ksds file records into cobol program?
Why is it necessary that file needs to be opened in I-O mode for REWRITE?
Explain the configuration section of a cobol program with examples of syntax.
) How do u handle errors in BMS macro
What the difference is between continue and next sentence?