• zSandbox

    This sandbox has been established by Mainframe Cloud. Mainframe connectivity is provided via an IBM System z® Personal Development Tool (zPDT). All solutions showcased in this sandbox have been designed by Mainframe Cloud for IBM System z® (z/OS).

  • About

    Mainframe Cloud solutions showcased in this sandbox are intended for learning & demonstration purposes only.

     

    Connection to z/OS assets is via Mainframe Cloud's InterActive Adaptor™ - an 'on-demand' service for mainframe. Communication between the InterActive Adaptor™ & calling applications is via a proprietary web service bridge developed by Mainframe Cloud for this sandbox.

     

    All microservices (apps) presented in this Sandbox utilise Mainframe Cloud's MainSpace™ product.

     

    MainSpace™ is an SDK which provides a set of purpose-built API methods that reduce the complexity of working with mainframe data sources. All example/demo apps showcased in this sandbox are coded in JavaScript.

  • Db2 Unload

    Unload & transform large volumes of Db2 data.

    Db2 to MySQL

    Unload a mainframe Db2 table to a cloud-hosted MySQL database.

    Db2 to CSV File

    Unload a mainframe Db2 table to a CSV file.

  • Db2 API

    Creating microservices for System z has never been easier.

    Db2 Queries

    The following examples execute a range of SQL queries.

    Db2 Query

    Execute a simple SQL query. Display return JSON response object.

    Db2 Query with JSON input

    Execute a simple SQL query (with JSON object as input). Display return JSON response object.

    Db2 Query (Table Display)

    Execute a simple SQL query. Extract data from the return response object for display.

    Execute Multiple SQL Statements

    The following examples execute SQL Pipes.

    A Pipe executes multiple SQL statements in sequence within a Db2 session.

    After each SQL statement is complete, the next SQL statement in the Pipe is executed.

    Simple Pipe

    A simple SQL Pipe example.

     

    Pipe (JSON Input)

    A Pipe example using a JSON object for input.

     

    Pipe (Table Display)

    This Pipe displays the return response for each SQL query in a simple HTML table display.

    Build Powerful Db2 Applications

    The following examples demonstrate the Query Process Engine (QPE), a valuable tool for building complex Db2 applications. QPE translates multiple SQL rules into SQL statements using criteria objects passed at run-time.

    SQL statements are then executed via an SQL Pipe.

    QPE for SQL Rules JS File

    QPE translates SQL rules into SQL statements using criteria objects passed at run-time. SQL statements are executed via an SQL Pipe.

    QPE for SQL Rules TXT File

    This example is identical to the previous example except that the SQL rules are read from a TXT file via XMLHttpRequest.

  • VSAM Unload

    Unload & transform VSAM files.

    VSAM to MySQL

    Unload a VSAM file to a cloud-hosted MySQL database. A VSAM flat file is converted into a structured database table as defined by its associated copybook.

    VSAM Files in Different Formats

    Read a VSAM file & display the content in the requested format (HEX, BASE64, EBCDIC, ASCII). Includes a copybook defined table view.

     

    VSAM to CSV File

    Unload a mainframe VSAM file to a CSV file.

    A VSAM flat file is converted into a spreadsheet table view as defined by its associated copybook.

     

  • JSFiddle

    Use JSFiddle to work with sample code for Db2, VSAM and the z/OS File System.