MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Easy way to get rec count

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
Kannan
Beginner


Joined: 13 Mar 2003
Posts: 5
Topics: 2

PostPosted: Fri Mar 21, 2003 11:40 am    Post subject: Easy way to get rec count Reply with quote

Hi,

My aim is to get the record counts of 30 seq files. Ultimately these rec counts have to be updated in a VSAM file. I can write a COBOL program to do this task. Please let me know is there any other way.

If writing COBOL program is the only way, then I wanted to discuss the following. Performance wise I am looking for a better option.
Option 1 : Open all the files
Reading one after another to get record count of each file
update VSAM file
Close all the files
Option 2 : Open first file A
Read the file A until eof
update VSAM file for the record count of fileA
CLose file A
<Do the same process for all the 30 files>
Looking forward to have better option. Thanks for your help, Kannan
Back to top
View user's profile Send private message
CaptBill
Beginner


Joined: 02 Dec 2002
Posts: 100
Topics: 2
Location: Pasadena, California, USA

PostPosted: Fri Mar 21, 2003 12:06 pm    Post subject: Reply with quote

If you just want a record count then the following VISION: Results or DYL-280 program will give you what you asked for.
Code:

//DYL280     EXEC PGM=DYL280                         
//SYSPRINT DD  SYSOUT=*                               
//SYSOUT   DD  SYSOUT=*                               
//SYS004   DD  UNIT=SYSDA,SPACE=(TRK,(10,5))         
//*                                                   
//SYS280R  DD  SYSOUT=*                               
//*                                                   
//YOURFILE   DD  DSN=you.actual.file.name,DISP=SHR   
//SYSIN     DD *                                     
FILE YOURFILE                                         
/*
//


After is is run, one of the outputs is a record and character count for each file,
Code:

COMPUTER ASSOCIATES       VISION:RESULTS  5.0 *           
         1         2         3         4         5         
12345678901234567890123456789012345678901234567890123456789
VISION:RESULTS CONTROL TOTALS                             
                                                           
FILE       RECORD         CHARACTER     BLOCK     DROPPED 
 ID         COUNT           COUNT       COUNT   BLOCK COUNT
                                                           
YOURFILE         200            70,400                     
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vallishar
Beginner


Joined: 17 Dec 2002
Posts: 53
Topics: 14
Location: BengaLuru

PostPosted: Fri Mar 21, 2003 12:40 pm    Post subject: Reply with quote

Hi,

Refer to the following links, you could get the record count using SORT/ICETOOL.

http://www.mvsforums.com/helpboards/viewtopic.php?t=361

http://www.mvsforums.com/helpboards/viewtopic.php?t=360
_________________
If you're not failing every now and again, it's a sign you're not doing anything very innovative.
Back to top
View user's profile Send private message Yahoo Messenger
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group