Can anyone please give the example of Inline Perform.
Answers were Sorted based on User's Feedback
Answer / shanuss
PERFORM UNTIL I = 10
MOVE RATE(I) TO SPLIT-TOT(1)
ADD 1 TO I
END-PERFORM.
Is This Answer Correct ? | 4 Yes | 0 No |
Answer / nikhil
There is one special thing about inline performs - there
has to be a END-PERFORM associated with the perform
statement otherwise it will give compile error. I have
tried this as well.
Is This Answer Correct ? | 3 Yes | 0 No |
Answer / abhishek vashishta
PERFORM UNTIL WS-EXIT = 'Y'
DISPLAY 'ENTER UR NAME '
ACCEPT WS-NAME
DISPLAY 'WANT TO EXIT'
ACCEPT WS-EXIT
END-PERFORM.
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / anjan
HI,
Inline perform is like inline function in C++. which
means in this case the control will not transfered to any
particular paragraph where as Immediately throws the result
of the code which has mentioned in the block perform and
end-perform.
Please correct me if i am wrong.
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / bijay krishna mohapatra
perform varyiung i from 1 by 1 under i>5
display i
add 1 to i
end perform
display 'bijay'
stop run.
***********rules********:
1.in line should be terminated into scope delimiter(end-if)
2.we cant apply the after opt.
3.nesting can be done hr.
Is This Answer Correct ? | 1 Yes | 1 No |
i have two file, each file having : file1 is having 2 fields field1 field2 file2 is having 3 fields field1 field2 field3 my req is to make it one file like: field1 field2 field1 field2 field3 if anyone know please send me syntax, i tried this with DFSORT but could not succeed.
01 b pic +9(4) How many bytes it will take for storage???
How many bytes S(8) comp field occupy and its maximum value?
i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com
How do u debug a S0C7 abend? (aswered till we get the field which caused that) After knowing the field which caused that how do u know the record which caused that if it is in production env? (dumb) Ok let us assume that we got to know that 100th record caused that and I wanted to skip only 100th record from the file and process from 101th. How to do that in JCL using SORT? (tried with STOPAFT but ended up dumb when he said smthing else is ther)
what is SYNCHRONIZATION?
A table has two indexes defined. Which one will be used by the SEARCH?
can we declare s9(9)v9(9) in cobol ? if yes how many bytes it will occupy ?(urgent plz answer it)
how to pass 100 to s9(4) how r they inserted ?
input:- 12233344445555566666... output:- 1=1,2=4,3=9... Here firstno i.e 1 should be displayed and after that the alikeno.s should be added n displayed.i.e 2+2=4 like tat it goeson.
What are the differences bitween cobol and cobol-2?
What is XDC ?