OPS/MVS

 View Only
  • 1.  Does anyone have an example of using DNSREXX to access a DB2 database from OPS

    Posted Jul 03, 2018 04:48 PM

    I have a large database I need to access whenever we have an alert that requires a problem ticket to be created.   The dataset is 50k records.   I don't want to perform an EXECIO each time there is an alert, 1k a day, and read this file in each time.   Someone suggested to load the dataset in to a DB2 database and perform queries against that.   Does anyone have an example using OPS REXX to access the DB2 database?   Or does anyone have a more efficient way to read a 50K dataset each time.    I see that OPS has a function to read VSAM, I will look into finding the JCL to load the dataset into a VSAM file and play with that.   But we already have the dataset loaded to DB2.

     

    Thanks for any input.

     

    Chris Allamon



  • 2.  Re: Does anyone have an example of using DNSREXX to access a DB2 database from OPS
    Best Answer

    Broadcom Employee
    Posted Jul 04, 2018 06:44 AM

    Good morning Chris,

     

    OPS/REXX doesn't support DSNREXX.
    But you can execute a (DB2) TSO/E rexx from an OPS REXX or an OPS rule:
    ADDRESS TSO EXEC 'your.rexx.library(DB2rexx)' or from a rule
    Address OSF EXEC 'your.rexx.library(DB2rexx)

     

    2 samples you could use as base.

    Sample 1 (DB2REXX) :

     

    Sample 2 (call DB2SQL):



  • 3.  Re: Does anyone have an example of using DNSREXX to access a DB2 database from OPS

    Posted Jul 05, 2018 12:14 PM

    Thanks a lot Hennie, after looking at it I am going to attempt to access the data through VSAM first and use the OPSVSAM function.  if I can't get that to work properly I will use the DSNREXX.  I will keep this in my holster, thank you.