give the examples for strings and unstrings in cobol
Answers were Sorted based on User's Feedback
Answer / gopi
String: It is a command which is to concatenates multiple variables into a single variable.
Ex: STRING yy,
"-",
mm,
"-",
dd
deliminate by size
Into ws-date.
End-string.
Unstring:It is a command which is to deconcatenates single variable into a multiple variables.
Ex: UNSTRING
ws-date.
deliminate by "-"
INTO
yy,
mm,
dd
End-string.
| Is This Answer Correct ? | 9 Yes | 2 No |
Answer / mohan.ch
string-add the 2 or more ws-vars to one ws-var
eg:-string ws-var1,ws-var2,ws-var3,ws-var4
into ws-var5
wel'
come,
to,
india
o/p wel come to india
unstring-split the varables to multiple
reverse of srting
| Is This Answer Correct ? | 6 Yes | 0 No |
can you declare redefine in level 01?
hi, can you ppl tell me, how to check whether the rewrite we gave for the ksds file is successful or not in the program.? i gave rewrite, the rewrite code is executing and maxcc=0 but updation doenot happen in the file?
what is index and how to use two tables using index?
What are the access modes of START statement?
select TURE Statement(s) aboUt eject statemenet in cobol? a)The eject statememnt must be the only statement on the line b.It causes the program to edit abnormally c. eject statement can be written in either area A or area B d. specifies that the next source statement is to be printed at Top of the next page e.The EJECTstatement has no effect on the compilation of the source program itself
Read a flat file and write last but one (I have n records in a file I have to write n-1th) record in another flat file. Could you please provide me the code in COBOL?
Explain fixed length record in cobol? with suitable example
why do u need inspect verb?
i have mainprogram and subgram...if i compile mainprogram without stop run..what will u get in compilation time?
How To move a value to an array using move verb?
In the JCL, how do you define the files referred to in a subroutine ?
if a>b continue display x. dispaly y. end-if display 1 display 2. display 3. what should be my output ?