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
 

 

Count number of records and set return code.

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

New User


Joined: 14 Sep 2005
Posts: 74
Location: Kentucky, USA

PostPosted: Mon Jul 20, 2009 11:29 pm    Post subject: Count number of records and set return code.
Reply with quote

Hi,

Is there a way in sort or iceman through which we can count number fo records in a flat file and based on that set the return code of that step.

For example, in my case I need to count records in a file and then set return code of 16 if the number for records exceeds 100,000.

Please let me know if above is possible.

Thanks,
Muffazel
Back to top
View user's profile Send private message

Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Mon Jul 20, 2009 11:43 pm    Post subject: Reply to: Count number of records and set return code.
Reply with quote

muffirulz,

Check the Smart DFSORT trick "Set RC=12 or RC=4 if file is empty, has more than n records, etc" here

http://www.ibm.com/support/docview.wss?rs=0&uid=isg3T7000094
Back to top
View user's profile Send private message
muffirulz

New User


Joined: 14 Sep 2005
Posts: 74
Location: Kentucky, USA

PostPosted: Tue Jul 21, 2009 1:07 am    Post subject: Reply to: Count number of records and set return code.
Reply with quote

Hi Skolusu,

The code works fine but it can set only return code of 0 or 12. I need to set it to 16.

Thanks,
Muffazel
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Tue Jul 21, 2009 2:36 am    Post subject:
Reply with quote

Quote:
I need to set it to 16.


Why? What will RC=16 do that RC=12 won't?
Back to top
View user's profile Send private message
muffirulz

New User


Joined: 14 Sep 2005
Posts: 74
Location: Kentucky, USA

PostPosted: Wed Jul 22, 2009 9:13 pm    Post subject: Reply to: Count number of records and set return code.
Reply with quote

Thanks Skolusu.

I used the solution from the reference and it worked fine.
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 Capture the Max return code of... anilkumar922 All Other Mainframe Topics 0 Thu Jan 12, 2017 12:02 pm
This topic is locked: you cannot edit posts or make replies. Calling REXX code from ISPF panel sanchita dey TSO/ISPF 4 Mon Jan 02, 2017 5:13 pm
No new posts Removing Duplicates based on certain ... chandracdac DFSORT/ICETOOL 8 Fri Dec 09, 2016 4:40 am
No new posts PL/I code tuning/Performance improvement Virendra Shambharkar PL/I & Assembler 4 Mon Dec 05, 2016 11:57 am
No new posts What is the code in CLIST to enable t... jackzhang75 CLIST & REXX 1 Fri Dec 02, 2016 3:02 am


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