01 a pic s9(5) value -12345,
if we disply a , the sign will overpunched with last digit
but i need to get the miuns sign in the result?
Answer Posted / mr.perfect
01 A pic s9(5) value -12345
01 B pic +9(5)
PROCEDURE DIVISION
MOVE A TO B
DISPLAY B
STOP RUN
o/P:
-12345
Will this work?
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
How do you define a variable of comp-1 and comp-2?
Are you comfortable in cobol or jcl?
Why is it necessary that file needs to be opened in I-O mode for REWRITE?
How you can read the file from bottom?
How many sections are there in data division in COBOL?
i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com
INREC AND OUTREC? HOW TO SPLIT 5K RECORDS TO DIFFERENT FILES IN A FILE IN COBOL? RESTART IN COBOL-DB2? ISOLATION LEVELS?
What is perform what is varying?
Write a cobol program making use of the redefine clause.
What is the difference between a binary search and a sequential search? What are the pertinent cobol commands?
What is link edit in cobol?
what is difference between cobol and cobol/400
Explain the configuration section of a cobol program with examples of syntax.
What is the difference between PIC 9.99 and 9v99 in COBOL?
how do you reference the variable block file formats from cobol programs