Go to Home Page
Questions?
Call 1-800-572-5517
 
  Go to Home Page  
  See all products
  See price schedules
  See manuals, tutorials, articles
  Download a free 30-day trial
  See user testimonials
  About Pacific Systems Group
 
 
SMF Tools
  See SMF Record Layouts
  See Sample SMF Reports
  Learn How to Export SMF Data
  Download Free SMF Reporting Software (30 days)
 
One of the greatest SMF record parsing programming languages I've ever seen. Chief, Large Systems Services Branch, NIH
  Choose Spectrum Writer to add 4GL to your product
  Report Writer Speedup Tips Article
Spectrum SMF Writer - Low-Cost 4GL Report Writer for SMF Files.

Sample Report from SMF 101 Records
Showing Response Times for DB2 Transactions

It's easy to report on SMF data!
 

SMF Spectrum Writer
We have a low-cost 4GL report writer especially for SMF files. It's called Spectrum SMF Writer.

Spectrum SMF Writer handles the difficult SMF record parsing for you automatically. You just specify which fields you want to see.

Spectrum SMF Writer also converts the arcane date and time fields and reformats them into an attractive report.

Plus Spectrum SMF Writer even exports SMF data as comma delimited files to use on your PC.
 
Try It FREE Now!


The sample SMF report below was created with Spectrum SMF Writer, the low-cost 4GL SMF report writer.

In this report, we want to show the response time and CPU time for individual DB2 transactions.

Here is how to get response time from Class 1 metrics (according to a white paper found here):

    Class 1 elapsed time has to be calculated as the difference between
            Ending Store Clock Time  (QWACESC) and Beginning Store Clock Time (QWACBSC)

    Class 1 CPU time has to be calculated as the sum of the CPU seconds used by:
    -- Main task; calculated as the difference between Ending CPU Time (QWACEJST) and
       Beginning CPU Time (QWACBJST)
    -- Stored procedures (QWACSPCP)
    -- UDF (QWACUDCP).

Below are the simple Spectrum SMF Writer control statements that implement this.

All of this with just a few lines of code!
Why not install a Spectrum SMF Writer trial right now and start making your own SMF reports!

These Spectrum SMF Writer Statements:

OPTION: MAXINCLUDE(20) /* LIMIT RUN SIZE WHILE TESTING*/             
                                                                     
**********************************************************************
* NAME THE INPUT FILE AND DEFINE THE 101 V11 FIELDS                  *
* NORMALIZE THE QWAC SECTION (PROCESS ALL OCCURRENCES)               *
**********************************************************************
INPUT:  SMF10111
        NORMWHEN(SMF101_IFCID3 AND QWA01R1N > 0)
        NORMSMF(QWA01R1O)                                            
                                                                     
**********************************************************************
* INCLUDE ONLY 101 RECORDS FROM INPUT FILE                           *
**********************************************************************
INCLUDEIF: SM101RTY=101                                              
                                                                     
**********************************************************************
* COMPUTE ELAPSED AND CPU TIMES FROM SMF FIELDS                      *
* #MAKENUM CHANGES TIME DATA (NN:NN:NN) TO NUMERIC SECS (NNN.NNNNN)  *
**********************************************************************
COMPUTE: ELAPSED-SECS  = #MAKENUM(QWACESC - QWACBSC) /*END MINUS BEG*/
COMPUTE: MAIN-CPU-SECS = #MAKENUM(QWACEJST - QWACBJST)               
COMPUTE: TOTAL-CPU-SECS = MAIN-CPU-SECS                              
         + #MAKENUM(QWACSPCP) /* ADD "STORED PROCEDURES" TIME */     
         + #MAKENUM(QWACUDCP) /* ADD "UDF" TIME */                                                           
                               
**********************************************************************
* NAME THE COLUMNS WE WANT TO SEE ON THE REPORT                      *
**********************************************************************
COLUMNS:                                                             
     SM101DTE('SMF DATE')  SM101TME('SMF TIME')                      
     QWHCEUID(10,'USER ID')                                          
     QWHCEUTX(10,'TRANS.ID')                                         
     QWACBSC('BEG TIME')                                             
     QWACESC('END TIME')                                             
     ELAPSED-SECS(PIC'ZZ9.999999')                                   
     MAIN-CPU-SECS(PIC'ZZ9.999999')                                  
     TOTAL-CPU-SECS(PIC'ZZ9.999999')                                 
                                                                     
**********************************************************************
* SPECIFY THE REPORT TITLE                                           *
**********************************************************************
TITLE: #DATE #TIME / 'DB2 RESPONSE TIME REPORT' / 'PAGE' #PAGE       

 

Produce This SMF Report:

 03/11/17  8:41 PM                         DB2 RESPONSE TIME REPORT                                PAGE    1

                                                                                          MAIN      TOTAL
                                                                             ELAPSED      CPU        CPU    
 SMF DATE  SMF TIME    USER ID    TRANS.ID     BEG TIME        END TIME        SECS       SECS       SECS   
 ________ ___________ __________ __________ _______________ _______________ __________ __________ __________

 10/13/09 20:46:33.18 rmsprod    perl       01:46:33.174587 01:46:33.180247   0.005660   0.001892   0.001892
 10/13/09 20:46:33.18 rmsprod    perl       01:46:33.182359 01:46:33.184985   0.002626   0.000665   0.000665
 10/13/09 20:46:33.19 rmsprod    perl       01:46:33.187028 01:46:33.191893   0.004865   0.000682   0.000682
 10/13/09 20:46:33.31 rmsprod    perl       01:46:33.305910 01:46:33.315605   0.009695   0.000599   0.000599
 10/13/09 20:46:33.33 rmsprod    perl       01:46:33.324745 01:46:33.334389   0.009644   0.001883   0.001883
 10/13/09 20:46:33.35 rmsprod    perl       01:46:33.336540 01:46:33.350454   0.013914   0.001773   0.001773
 10/13/09 20:46:33.35 rmsprod    perl       01:46:33.352545 01:46:33.357884   0.005339   0.000532   0.000532
 10/13/09 20:46:33.36 rmsprod    perl       01:46:33.359754 01:46:33.369086   0.009332   0.001839   0.001839
 10/13/09 20:46:33.37 rmsprod    perl       01:46:33.372015 01:46:33.377884   0.005869   0.000681   0.000681
 10/13/09 20:46:33.39 rmsprod    perl       01:46:33.379804 01:46:33.390194   0.010390   0.000584   0.000584
 10/13/09 20:46:33.45                       00:00:00.000000 00:00:00.000000   0.000000   0.000000   0.000000
 10/13/09 20:46:33.45                       01:46:33.062795 01:46:33.457480   0.394685   0.030574   0.030574
 10/13/09 20:46:33.47                       01:46:33.464090 01:46:33.476195   0.012105   0.000624   0.000624
 10/13/09 20:46:33.51 rmsprod    perl       01:46:33.505705 01:46:33.515334   0.009629   0.000572   0.000572
 10/13/09 20:46:33.54 rmsprod    perl       01:46:33.523682 01:46:33.540041   0.016359   0.001819   0.001819
 10/13/09 20:46:33.54 rmsprod    perl       01:46:33.542616 01:46:33.548360   0.005744   0.001771   0.001771
 10/13/09 20:46:33.55 rmsprod    perl       01:46:33.550364 01:46:33.558284   0.007920   0.000517   0.000517
 10/13/09 20:46:33.56 rmsprod    perl       01:46:33.560054 01:46:33.568153   0.008099   0.001859   0.001859
 10/13/09 20:46:33.57 rmsprod    perl       01:46:33.570431 01:46:33.574913   0.004482   0.000631   0.000631
 10/13/09 20:46:33.58 rmsprod    perl       01:46:33.576989 01:46:33.584029   0.007040   0.000613   0.000613

 *** GRAND TOTAL (    20 ITEMS)                                               0.543397   0.050110   0.050110


See Other Sample SMF Reports
Copyright 2024.
Pacific Systems Group.
All rights reserved.


Spectrum Writer 4GL - the economical alternative to SAS, Easytrieve, DYL-280...

Home | Products | Prices | Documentation | 30-Day Trials | Customer Reviews | Company | FAQ | Sample Reports | SMF Records
Send Your Comments or Questions