how can we find total no of records in a file ....is there
any utility......?
Answers were Sorted based on User's Feedback
Answer / vivek c
Use ICETOOL utility as below.
//TOOLIN DD *
COPY FROM(IN1) USING(CTL1)
/*
//CTL1CNTL DD *
OUTFIL FNAMES=OUT,REMOVECC,NODETAIL,
TRAILER1=('FILE1',5X,COUNT=(M10,LENGTH=5))
/*
Is This Answer Correct ? | 5 Yes | 0 No |
Answer / varsha
//SYSIN DD *
INREC FIELDS=(1,4,C'00001')
SORT FIELDS=(01,04,CH,A)
SUM FIELDS=(05,05,ZD,A)
OUTREC FIELDS=(01,04,05,05)
/*
Briefly, I'm adding a numeric 00001 to each record and
sorting them on the numeric field and summing all such
records, which will give you the desired output.
Is This Answer Correct ? | 1 Yes | 0 No |
What are declaratives and what are their uses in cobol?
What guidelines should be followed to write a structured Cobol program?
How do define dynamic array in cobol. how do you define single dimensional array and multidimensional array in your cobol?
Consider the following: 77 A PIC 9(10) 77 B PIC 9(10) 77 C PIC 9(19) MULTIPLY AB BY B GIVING C Which of the following is true ? (a) The execution of the above may result in size error. (b) The execution of the above will result in size error. (c) The definition of C is invalid resulting in compilation error. (d) No error will be thee and the program would proceed correctly.
input:- A 10 20 30 40 B 5 7 10 14 C 8 12 14 16.... output:- A = 100,B=36,C=50. Here spaces are considered between numbers. When we give input as above, the numbers should be added n displayed.So please help me out.
01 MOVE 10 TO N 05 PERFOM PARA1 TIMES STOP RUN WAT WILL HAPPEN?? WILL IT RUN INFINITELY OR AN ERROR WIL BE THER BECAUSE NO OF TIMES IS NOT GIVEN??
What is JOBLIB and STEPLIB in JCL? what is the purpose of using it?
what is the advantage of using redefines instead of delaring the variables ?
what is scope terminator
What is the difference between a subscript and an index in a table definition?
What is tne need to use sub programs in Cobol?
plz any one tell clearly the justify right clause?