I have a File that has duplicate records. I need only those records that occur more than
thrice.?
Answer Posted / supreethi
Code:
//*******************************************************
//STEP001 EXEC PGM=ICETOOL
//TOOLMSG DD SYSOUT=*
//DFSMSG DD SYSOUT=*
//IN1 DD *
AAAAAAAAA
VVVVVVVVV
GGGGGGGG
AAAAAAAAA
HHHHHHHHH
AAAAAAAAA
GGGGGGGG
VVVVVVVVV
/*
//TMP1 DD DSN=&&TEMP1,DISP=(MOD,PASS),SPACE=(TRK,(5,5)),UNIT=SYSDA
//OCCUR1 DD SYSOUT=*
//OCCUR2 DD SYSOUT=*
//OCCUR3 DD SYSOUT=*
//TOOLIN DD *
OCCUR FROM(IN1) LIST(OCCUR1) EQUAL(1)-
ON(1,9,CH) ON(VALCNT,N04)
OCCUR FROM(IN1) LIST(OCCUR2) EQUAL(2)-
ON(1,9,CH) ON(VALCNT,N04)
OCCUR FROM(IN1) LIST(OCCUR3) EQUAL(3)-
ON(1,9,CH) ON(VALCNT,N04)
/*
OCCUR1 contains:
Code:
---+----1----+----2----+
(1,9,CH) VALUE COUNT
HHHHHHHHH 1
OCCUR2 contains:
Code:
---+----1----+----2----+
(1,9,CH) VALUE COUNT
GGGGGGGG 2
VVVVVVVVV 2
OCCUR3 conatains:
Code:
---+----1----+----2----+
(1,9,CH) VALUE COUNT
AAAAAAAAA 3
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
please..could u give an example about USAGE IS POINTER ..and explain why and when we use it ?
how to convert the recors form vsam file to db2 table tru file aid
I need to compare 3 variables(dates) and do some processing based on the earliest date. There could be more then 1 date record in any of the 3 fields. What is the best way to code this?
Why occurs cannot be used in 01 level in COBOL?
What is difference between static and dynamic call in cobol?
Name the divisions, which are available in a cobol program?
IF I mention stop run in CICS what happens?
What is an in line perform? When would you use it? Anything else you wish to say about it.
What is the difference between binary search and sequential search?
how to access the file from prodution from changeman tool and to submit a file to production
What is the problem of ordered sequential files access?
Our issue is there seems to be a disconnect, or no link, between our SELECT statement and our SD. We had SELECT SORT-FILE and SELECT SORT-FILE ASSIGN TO SORTWRK. ASSIGN TO SORTWRK1 SORTWRK2 SORTWRK3 SORTWRK4. with SD SORT_FILE RECORD CONTAINS 7833 CHARACTERS. In either case, at run time, the system ignored our SORTWRK# DD statements and allocated 16 sort works with the SORTWK## naming convention. Any ideas why the system does not recognize the connection? We do not even need the SORTWRK DD statements. Thanks
What are the pertinent COBOL commands?
When is inspect verb is used in cobol?
How to know whether the module is dynamical or statistical?