Toad for DB2 - The easy way of transferring scripts from Toad files to PDS member on z/OS

If you work with Toad for DB2 on your DB2 subsystem, it happens quite often that your work results in a DDL or DML script in the editor. It can’t be executed directly but needs to be scheduled for running in the night. Now you have the challenge to transfer it to your mainframe.

No worries, if you use Toad you can easily transfer your script into a PDS member. Before you can start, please ensure this: On each DB2 for z/OS subsystem on which you want to execute remote scripts via Toad, you must have both the Toad IBM DB2 z/OS component and the SYSPROC.DSNUTILU procedure installed. For information about installing the z/OS component, see the Toad IBM DB2 z/OS Component Installation Guide.

If this is done, simply follow these steps:

  1. Connect to a DB2 subsystem with Toad

          

  1. Open your SQL script into the editor of Toad. Our example is a very simple select query.

         

  1. Open the “Editor” pull-down menu and select “Remote job Execution”:

         

  1. The Remote Script Execution Wizard of Toad appears. You are asked to select the target DB2 subsystem, User-ID and password, which is used to connect to it.

         

  1. Review the job card:

          

         A default job-card can be specified under Tools/Options in Toad:

         

 

  1. Review the whole JCL. This text will be taken and written into the specified PDS member on the host. You can edit here if necessary.

         

  1. Select the target partitioned data set to which you want to save your script either via typing it directly or filter and query it and specify the name of the PDS member:

         

         Easily query a PDS on your host:

         

  1. Select the transfer protocol (you can choose between FTP and SFTP) and click next. The server address is the IP address of the DB2 subsystem on the mainframe.

         

  1. The result: You have transferred your script into a PDS member.

        

        

Anonymous