can we display comp-3 variables. if we want to display what
we have to do . give me one example
Answers were Sorted based on User's Feedback
Answer / craig
You can display them, but they will appear non-numeric.
Move the field to a WS field defined as pic +9('number of
digits') and display the WS field to make the data user-
friendly.
Is This Answer Correct ? | 22 Yes | 4 No |
Answer / vivekananda
We can't display COMP-3 directly so we have to move the value into another variable, check this given example.
01 A1 PIC S9(4) COMP-3 VALUE 1234.
01 A1-NUM PIC S9(4) VALUE ZEROES.
01 B1 PIC X(4).
MOVE A1 TO A1-NUM.
MOVE A1-NUM TO B1.
DISPLAY B1.
Is This Answer Correct ? | 25 Yes | 7 No |
Answer / narayana g
You can display the COMP-3 variable by redefining to numeric
variable.
Is This Answer Correct ? | 16 Yes | 2 No |
Answer / antony
We will get the actual value of the variable, so we need to
either redefine or move that to an equivalent numeric
variable to display it.
Is This Answer Correct ? | 9 Yes | 1 No |
What is the file organization clause ?
Following questions were asked in Capegemini on 8th sep,2012 mainframe test 1.)Condition code for dul recors in VSAM- 2.) Is NULL or =NULL in Select statement 3.)max size of CI 4.)What happens after CI is full 5.)Ques on COND parameter 6.)which among following can not be rolled back a)delete table b.)droptable c)Update d.)insert 7.)groupby and orderby sql querries 8.)Max extents in VSAM file 9.)quesn on DPRTY=(1,10) 10.)range of condition codes in COBOL 11.)occurs clase can not be used at which level? 12.)delimiter in jcl 13.)sort card for file in PGM=SORT 14.)PIC(6) value 120056 possible? 15)question on BLKSIZE Is (20,20) and (20,10) possible? 16.)number of bytes in RDF 17.)Can we use index in WS-section or LK-section 18.)Verify command in IDCAMS used for? 19.)question on Alternate Index 20.)Return code of file attribute mismatch 21.)In which format COBOL variables stored? 22.)what is Alternate of HANDLE? 23.)can SUM,AVG,MIN,ROUND used in numeric and char variable data types? 24.)What is the datatype of FILE STATUS codes in WS-section?
What is the difference between a binary search and a sequential search? What are the pertinent cobol commands?
The following entries appear in the WORKING-STORAGE SECTION: 01 DATE-TODAY. 05 YY PIC XX VALUE "90". 05 MM PIC XX VALUE "12". 05 DD PIC XX VALUE :31". 01 DATE-EDIT PIC XX/XX/XX. MOVE DATE-TODAY TO DATE-EDIT. (a) 901231 (b) 90/12/31 (c) 31/12/90 (d) 311290
what is level 66 means??
what is ASRA, AEY9?
Name the divisions in a COBOL program ?
how we sort two input files based on a common column and giving one o/p file please send me the coding logic?
Which is not true about evaluate statement
what is the default print format? in cobol
What are decleratives in COBOL ?
What is the difference between NEXT SENTENCE and CONTINUE?