Uriel, you have to basically extract the dcollect data and pass it into a 
program such as SAS/MXG/SORT/etc. and define the input record layout and your 
formatted output layout.

You have to also compensate for the different type of records such as Type D 
for dataset A for VSAM and V for volume and so on...see manual.

So for vsam for example, you might use SAS to process the records as below.  
This is an excerpt from a SAS pgm I use to monitor space utilization.

INFILE DCOLLECT     ; 
                                    
INPUT @005 RCTYP  $2. @ ;      

IF RCTYP EQ 'V ' THEN
  DO;                
     FORMAT TMSTP DATETIME.                            
            DATE  MMDDYY8.                             
            TIME  TIME.                                
            FREECYL                                    
            ALLOC                                      
            TOTCYL COMMA11.                            
            DVNUM  HEX3.                               
          ;                                            
     LABEL  FREECYL = 'KILOBYTES OF FREE SPACE'        
            ALLOC = 'KILOBYTES OF ALLOCATED SPACE'     
            TOTCYL = 'KILOBYTES OF TOTAL CAPACITY'     
            STORGROUP = 'STORAGE GROUP NAME'           
            FRAGI = 'FRAGMENTATION INDEX'              
            PCTFREE = 'PERCENTAGE FREESPACE REMAINING' 
            DVTYP = 'DEVICE TYPE'                      
            DVNUM = 'DEVICE NUMBER'                    
            ;                                          
                                                       
         INPUT @009 SYSID $4.                                       
               TMSTP SMFSTAMP8.                                
          @025 VOLSR $6.                                       
               FLAG1 $1.    /* STORAGE/PRIVATE/PUBLIC ETC.   */
          @036 PCTFREE PIB1. /* PERCENT FREE SPACE           */
               FREECYL PIB4. /* FREE SPACE ON VOLUME (IN KB) */
               ALLOC PIB4.  /* ALLOCATED SPACE ON VOL(IN KB) */
               TOTCYL PIB4. /* TOTAL CAPACITY OF VOL (IN KB) */
               FRAGI PIB4.  /* FRAGMENTATION INDEX           */
               LGEXT PIB4.  /* LARGEST FREE EXTENT           */
               FREXT PIB4.  /* FREE EXTENTS                  */
               FDSCB PIB4.  /* FREE DSCBS                    */
               FVIRS PIB4.  /* FREE VIRS                     */
               DVTYP $8.    /* DEVICE TYPE                   */
               DVNUM PIB2.  /* DEVICE NUMBER                 */
          @081 SGLNG PIB2.  /* STORAGE GROUP NAME LENGTH     */
               STORGROUP $8. /* STORAGE GROUP NAME           */


You would then add more logic to capture only the records you want and format 
the records to print the output records according to your needs.

That's pretty much it in a nutshell.  You can get as fancy as you want by doing 
calculations and what not but that's the basics.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to