Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Unique Record Count

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
anandhan87

New User


Joined: 09 Feb 2016
Posts: 1
Location: India

PostPosted: Tue Feb 09, 2016 4:06 pm    Post subject: Unique Record Count
Reply with quote

I have a PS file of LRECL 240 and RECFM FB and I am looking for the unique record count as output.

For Eg:

I/p File

AAAA 1111 AAAAAAAA
AAAA 1111 AAAAAAAA
AAAA 1111 AAAAAAAA
BBBB 2222 BBBBBBBB
BBBB 2222 BBBBBBBB
BBBB 2222 BBBBBBBB
CCCC 3333 CCCCCCCC
CCCC 3333 CCCCCCCC
CCCC 3333 CCCCCCCC

O/P should be

RECORD STATS REPORT
---------------------------

Total No.of Records = 3
Back to top
View user's profile Send private message

Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7223

PostPosted: Tue Feb 09, 2016 6:45 pm    Post subject: Reply to: Unique Record Count
Reply with quote

Use WHEN=GROUP and OUTFIL reporting features,

Code:
  OPTION COPY
                                           
  INREC IFTHEN=(WHEN=GROUP,KEYBEGIN=(1,18),
               PUSH=(19:ID=5),RECORDS=1)
  OUTFIL INCLUDE=(19,5,CH,NE,C' '),
         REMOVECC,
         NODETAIL,
         TRAILER1=(C'Total No.of Records = ',
                   19,5)


If you really want the count left-justified and with no leading zeros, you should be able to manage that yourself with WHEN=INIT in INREC or OUTREC.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts How to update a portion of text in a ... Bill Woodger DFSORT/ICETOOL 25 Wed Nov 09, 2016 9:41 pm
No new posts abend sort based on count records in ... anatol DFSORT/ICETOOL 5 Mon Oct 17, 2016 10:10 pm
No new posts sort with previous record anatol DFSORT/ICETOOL 9 Thu Oct 06, 2016 2:36 am
No new posts Get Record count in summary record fo... Atul Banke DFSORT/ICETOOL 21 Fri Sep 23, 2016 4:17 pm
No new posts Change date (DD/MM/YY) in 2nd record ... uday kiran DFSORT/ICETOOL 12 Wed Sep 07, 2016 10:57 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us