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
 

 

Records count without using ISREDIT

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
Vamshi Veludandi

New User


Joined: 17 Mar 2009
Posts: 23
Location: Bangalore

PostPosted: Fri Feb 10, 2012 1:00 pm    Post subject: Records count without using ISREDIT
Reply with quote

I have a PS file with huge amount of records in it and I need to get the total number of records using REXX.

I tried using STEM variables, but since it so huge I'm getting Memory allocation error.

Is it possible to get the job done, without using STEM variables and ISREDIT ?

A code snippet for the same would be much helpful.

Regards,
Vamshi
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Fri Feb 10, 2012 1:39 pm    Post subject:
Reply with quote

Yes it would be possible, but EXECIO is not a great way to do it as it is quite inefficient for large data volumes.

You could read the file via IEBGENER or SORT, outputting to a dummy file, and then parse the SYSOUT / SYSPRINT output to get the count.

But why do you need to do this, if the creating programs were written correctly this information should already be known.
Back to top
View user's profile Send private message
kalyan418

New User


Joined: 03 Jan 2007
Posts: 2
Location: chennai

PostPosted: Fri Feb 10, 2012 2:45 pm    Post subject: Reply to: Records count without using ISREDIT
Reply with quote

Is there any alternate way to do this reuirement using rexx
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7315

PostPosted: Fri Feb 10, 2012 2:55 pm    Post subject: Reply to: Records count without using ISREDIT
Reply with quote

Of course. Call SORT from rexx.

Here is a topic with some sort cards for counting.

Search here or the web for examples of using Sort from rexx.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 1788
Location: UK

PostPosted: Fri Feb 10, 2012 3:50 pm    Post subject:
Reply with quote

You could read one record at a time and count them or read a block of records at a time and accumulate totals. Drop the stem before doing the next read. Still a waste of resource when other utilities can do it much more efficiently.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
Location: italy

PostPosted: Fri Feb 10, 2012 7:17 pm    Post subject: Reply to: Records count without using ISREDIT
Reply with quote

Quote:
I have a PS file with huge amount of records in it and I need to get the total number of records using REXX.


then REXX is not the best tool for it!
there are novemtrigintillion examples on the forum ( JCL or DFSORT ) on how to do it using <SORT>
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
This topic is locked: you cannot edit posts or make replies. Merge two files and update Trailer re... Yashashri JCL & VSAM 1 Thu May 04, 2017 12:54 pm
No new posts RC 20 for Address ISPEXEC "ISRED... pkmurali CLIST & REXX 3 Sun Apr 16, 2017 11:30 pm
No new posts Count the length of the record & ... sreekusr DFSORT/ICETOOL 4 Thu Mar 23, 2017 7:52 pm
No new posts Display FTP Session Count within TSO Yolanda Harvey TSO/ISPF 3 Fri Mar 10, 2017 10:31 pm


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