give the examples for strings and unstrings in cobol

Answers were Sorted based on User's Feedback



give the examples for strings and unstrings in cobol..

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

give the examples for strings and unstrings in cobol..

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

Post New Answer

More COBOL Interview Questions

s9(18) comp-3:: What is the size of memory it takes internally?

4 Answers  


Explain Restart Logic in Cobol?

1 Answers   L&T, Syntel,


How can I find the maximum value of a field in a file while reading the file dynamically? without using sort function. Suppose i have a file with fields Timestamp, description, teamname, teamnumber.. i have read the file till end and find the maximun value of timestamp which is not in sorted order.. can we use function max(timestamp)?

1 Answers   CGI,


SSRange is used to do a range check on which of the Following. SUBSCRIPT,INDEX,REFERENCE MODIFICATION,Run-time option.

3 Answers   Lehman Brothers,


Why do we use COMP-3 variables for computation, when we know that they are non displayable fields and require additional MOVE to numeric field before we populate it in output Reports?

1 Answers   Accenture,


How to get the last record in vsam file in cluster? And how can you get the ksds file records into cobol program?

1 Answers  


EXPLAIN MAIN FRAME TESTING PROCESS...HOW TO FIX THE MAINFRAME BUGS?

1 Answers   Accenture,


In COBOL programming, what is PERFORM? What is VARYING?

1 Answers   CDC,


How may divisions are there in JCL-COBOL?

5 Answers   IBM,


What was removed from COBOL in the COBOL II implementation?

0 Answers  


What do you feel makes a good program?

2 Answers  


I know my query will return more than one row but I don't want cursor what should I do?

1 Answers  


Categories