i need a program by giving input as a abcd in any randem order
but i need a output as 1234 related to abcd. i.e,. a for
1,b=2,c.....etc..
Answer Posted / kamaldeep
We can use:
INSPECT ws-var1 CONVERTING 'ABCD' TO '1234'.
this will replace a with 1, b with 2, c with 3 & d with 4
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
I have program P1 which calls file F1 which has 100 records and following structure 001 .................. 002 .................. 003 .................. 098 .................... 099 ................... 100 .................... Now I want to read these files and write these records in file F2 in following manner. 001 ...... 051 ..... 002 ...... 052 ..... 003 ...... 053 ..... .......... ....... .......... ....... .......... ....... 048 ........ 098 ...... 049 .......... 099 ....... 050 .... 100 ......
Name the sections present in data division.
Why do we code s9 (4) comp. Inspite of knowing comp-3 will occupy less space?
Program A (Normal COBBAT) calling a B Program (DB2COBOL, COBBATDB which is using a VSAM file. its a dynamic call. How we will handle VSAM file decleration in our from JCL from where we are running A PGM. And should we have PLAN for A pGM also. if possible can some one post a sample JCL. Thanks for help in advance.
What is the difference between comp and comp-3?
What guidelines should be followed to write a structured cobol prgm?
Why did you choose to work with ibm mainframe cobol programming?
what is the difference between COBOL2 AND COBOL390?
What is the usage of comp fields in cobol?
How to get the last record in vsam file in cluster? And how can you get the kids file records into your cobol program?
What are declaratives and what are their uses in cobol?
Is it possible that the redefines clause has different picture clauses compared to the one it redefined?
What kind of error is trapped by on size error option?
What the difference is between continue and next sentence?
How can i load all the data from a file to Table (array) in cobol.How i manage the occurs clause with out reading the file.Any options avilable ? Please can any one help me it is urgent?