Remote Stored Procedures. n Customer-written CICS application programs n Provides LAN applications with access to CICS resources n Invoked by LAN-based.

Slides:



Advertisements
Similar presentations
PHP II Interacting with Database Data. The whole idea of a database-driven website is to enable the content of the site to reside in a database, and to.
Advertisements

Chapter 10: Designing Databases
Adding Dynamic Content to your Web Site
Chapter 3: Modularization
SYSTEM PROGRAMMING & SYSTEM ADMINISTRATION
Advantage Data Dictionary. agenda Creating and Managing Data Dictionaries –Tables, Indexes, Fields, and Triggers –Defining Referential Integrity –Defining.
Brian Alderman | MCT, CEO / Founder of MicroTechPoint Pete Harris | Microsoft Senior Content Publisher.
Technical Architectures
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 13 Introduction to SQL Programming Techniques.
Using Visual Basic 6.0 to Create Web-Based Database Applications
Interpret Application Specifications
Fundamentals, Design, and Implementation, 9/e Chapter 7 Using SQL in Applications.
Chapter 7 Advanced SQL Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
A Guide to SQL, Seventh Edition. Objectives Embed SQL commands in PL/SQL programs Retrieve single rows using embedded SQL Update a table using embedded.
CICS Basic Commands COBOL programming statements.
1 © Prentice Hall, 2002 The Client/Server Database Environment.
The Client/Server Database Environment
SEMESTER 1, 2013/2014 DB2 APPLICATION DEVELOPMENT OVERVIEW.
DB2. 2 Copyright © 2005, Infosys Technologies Ltd ER/CORP/CRS/DB01/003 Version No:2.0a Session Plan SPUFI Hands On Introduction to Embedded SQL DCLGEN.
Database System Concepts and Architecture Lecture # 3 22 June 2012 National University of Computer and Emerging Sciences.
Databases C HAPTER Chapter 10: Databases2 Databases and Structured Fields  A database is a collection of information –Typically stored as computer.
4-1 INTERNET DATABASE CONNECTOR Colorado Technical University IT420 Tim Peterson.
What is Architecture  Architecture is a subjective thing, a shared understanding of a system’s design by the expert developers on a project  In the.
Using Visual Basic 6.0 to Create Web-Based Database Applications
2. Database System Concepts and Architecture
CS 390- Unix Programming Environment CS 390 Unix Programming Environment Topics to be covered: Distributed Computing Fundamentals.
NMED 3850 A Advanced Online Design January 12, 2010 V. Mahadevan.
RELATIONAL FAULT TOLERANT INTERFACE TO HETEROGENEOUS DISTRIBUTED DATABASES Prof. Osama Abulnaja Afraa Khalifah
Triggers and Stored Procedures in DB 1. Objectives Learn what triggers and stored procedures are Learn the benefits of using them Learn how DB2 implements.
Introduction to the new mainframe © Copyright IBM Corp., All rights reserved. Chapter 12 Understanding database managers on z/OS.
Database Design and Management CPTG /23/2015Chapter 12 of 38 Functions of a Database Store data Store data School: student records, class schedules,
MIS 327 Database Management system 1 MIS 327: DBMS Dr. Monther Tarawneh Dr. Monther Tarawneh Week 2: Basic Concepts.
3-Tier Client/Server Internet Example. TIER 1 - User interface and navigation Labeled Tier 1 in the following graphic, this layer comprises the entire.
INFO1408 Database Design Concepts Week 15: Introduction to Database Management Systems.
Programmatic SQL Shaista Khan CS 157B. Topic Embedded SQL statements in high-level programming languages.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Copyright © 2004, SAS Institute Inc. All rights reserved. SAS Stored Processes An analyst’s perspective Sylvain Tremblay SAS Canada 24 February 2006.
Commercial RDBMSs Access and Oracle. Access DBMS Architchecture  Can be used as a standalone system on a single PC: -JET Engine -Microsoft Data Engine.
INTRODUCTION TO DBS Database: a collection of data describing the activities of one or more related organizations DBMS: software designed to assist in.
Accessing Relational Databases from the World Wide Web by Tam Nguyen & V. Srinivasan Presented by Megan Thomas and Randi Thomas CS294-7 February 11, 1999.
Experiment Management System CSE 423 Aaron Kloc Jordan Harstad Robert Sorensen Robert Trevino Nicolas Tjioe Status Report Presentation Industry Mentor:
Chapter 9: Advanced SQL and PL/SQL Guide to Oracle 10g.
Dr Gordon Russell, Napier University Unit Embedde SQL - V2.0 1 Embedded SQL Unit 5.1.
Introduction to the new mainframe © Copyright IBM Corp., All rights reserved. Chapter 11 Understanding transaction managers on z/OS.
A Guide to SQL, Eighth Edition Chapter Eight SQL Functions and Procedures.
Chapter 8 Embedded SQL.
In this module, we will design a program to work with the PROJECT table, learning to insert a new project into the table, to delete one or more projects.
NSF DUE ; Wen M. Andrews J. Sargeant Reynolds Community College Richmond, Virginia.
Integrating the Mainframe Liberating Enterprise Data.
Integrating the Mainframe Liberating Enterprise Data.
Client Services Applications. What are Client Services Applications? Access Server CICS Client Application Server Turns the traditional picture upside.
Opening the Box and Liberating S/390 Enterprise Data International Sales Meeting, June 1999 Bill Coleman and Peter King.
ViaSQL Technical Overview. Viaserv, Inc. 2 ViaSQL Support for S/390 n Originally a VSE product n OS/390 version released in 1999 n Identical features.
Wavv 2005 Colorado Springs. VSE Connectors VSE Connectors ViaSQL “Plus” Functionality ViaSQL “Plus” Functionality ViaSQL “Plus” Adaptability ViaSQL “Plus”
Dueling Middleware WAVV 2000, Colorado Springs. Middleware Defined LAN DBMS Web Browser Client Workstation Local Area Network Middleware Web Server S/390.
Migrating Mainframe Data Liberating Enterprise Data.
Middleware Solutions for VSE and. 2 Middleware products for data access, delivery, and integration. Designed for organizations seeking the combined benefits.
Text TCS INTERNAL Oracle PL/SQL – Introduction. TCS INTERNAL PL SQL Introduction PLSQL means Procedural Language extension of SQL. PLSQL is a database.
Integrating the Mainframe Liberating Enterprise Data.
Copyright 2007, Information Builders. Slide 1 iWay Web Services and WebFOCUS Consumption Michael Florkowski Information Builders.
ViaSQL Transfer. Viaserv, Inc. Transfer – 2 The ViaSQL Transfer n Available only with ViaSQL Integrator n Move data between OS/390 and a LAN database.
Lu Wei1 Outline Introduction Basic SQL Setting Up and Using PostgreSQL Advanced SQL Embeded SQL.
ViaSQL Access Server. ViaSQL Access Server Functions n Accept client requests –execute them against DB2 –execute specified RSP –connect to Legacy Data.
ViaSQL Legacy Data Server. Viaserv, Inc. 2 ViaSQL Legacy Data Server n “Relational engine” for non- relational OS/390 data n Functions –interface with.
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe.
ZEUS.
A Guide to SQL, Seventh Edition
Programming in COBOL.
Client Access, Queries, Stored Procedures, JDBC
Login Main Functions Via SAS Information Delivery Portal
Presentation transcript:

Remote Stored Procedures

n Customer-written CICS application programs n Provides LAN applications with access to CICS resources n Invoked by LAN-based client or web application n Invoked with USE or EXECUTE statement

From the Application Perspective... Data returned from an RSP is no different than data returned from a relational DBMS!

Stored Procedure Processing Access Server CICS USE PROCEDURE PAYHIST or EXECUTE PAYHIST RSP

Why Use Remote Stored Procedures? n Programmatic access to S/390 data and resources n Access unusual data sources or difficult data structures n Perform complex processing n Execute existing business logic

Typical Uses for RSPs n Desktop and web access to non-relational data –VSAM –IMS and DL/I –Datacom, Adabas, IDMS –Others n Static access to DB2 n Invocation of other CICS programs n Access to other CICS resources n ViaSQL TRANSFER operations

Modernize Existing CICS Applications n Preserve investment in existing business logic and applications n Just strip out the 3270 screen interactions n Add the appropriate RSP commands n Execute from desktop or web applications

Integrate 4GL Applications n Desktop and web access to S/390-based 4GL applications n Ideal for access to Datacom/DB n Natural for access to Adabas

Stored Procedure Programs n Customer written n Standard CICS application program n Supported languages –COBOL II –Assembler –PL/I –C

Stored Procedure API n Easy to use n CICS application issues Stored Procedure commands n Issued via standard system CALL n Stored Procedure Communication Area n Stub routines

Stored Procedure Commands n STATUSindicate outcome of processing n MESSAGEsend a message to the workstation n DESCRIBEobtain column information about a table n COMMITcommit work n ROLLBACKrollback work n OPENPIPEopen a data pipe n GETPIPEread a record from the data pipe n PUTPIPEwrite a record to the data pipe n CLOSPIPEclose the data pipe

Sample Stored Procedure ENVIRONMENT DIVISION. PROGRAM ID. PROGRAM3. ********************************************************************** * INSERT A ROW INTO THE DB2 EMPLOYEE MASTER TABLE * **********************************************************************. DATA DIVISION. 01EMPLOYEE-RECORD. 03SSNO PIC X(11). 03NAME. 05 NAME-LEN PIC S9(4) COMP. 05 NAME-TEXT PIC X(30). 03HIREDATE PIC X(10). 03EXEMPTS PIC S9(4) COMP. 03WAGE PIC S999V99 COMP-3. LINKAGE SECTION. 01DFHCOMMAREA. COPY SPAREAC.

Sample Stored Procedure - continued PROCEDURE-DIVISION. MOVE ' ' TO SSNO. MOVE 30 TO NAME-LEN. MOVE 'GROUCHO MARX' TO NAME-TEXT. MOVE ' ' TO HIREDATE MOVE 3 TO EXEMPTS. MOVE TO WAGE. PERFORM -INSERT-EMPLOYEE. IF SQLCODE = 0 THEN PERFORM ISSUE-OK ELSE PERFORM ISSUE-ERROR. EXEC CICS RETURN. INSERT-EMPLOYEE. EXEC SQL INSERT INTO Z271.SAMPLE_EMPLOYEE (SSNO, NAME, HIRE_DATE, EXEMPTIONS, HOURLY_WAGE) VALUES(:SSNO, :NAME, :HIREDATE, :EXEMPTS, :WAGE) ISSUE-OK. MOVE 'OK' TO SPSTATUS. CALL 'STATUS' USING SPAREA. ISSUE-ERROR. MOVE 'E ' TO SPSTATUS. CALL 'STATUS' USING SPAREA.

Output Pipes n Used to return multiple rows of data n Pipe must be open before use n Pipe must be closed after use n The PUTPIPE command is used to write data n STD and DB2 format output pipes n Access Server returns records in IXF format

STD Format Output Pipe n Stored procedure need not describe the data n Stored procedure supplies data in free-form n No data structure in IXF file

DB2 Format Output Pipe n Stored procedure describes data with SQLDA n Stored procedure supplies data in DB2 format n Data structure in captured in IXF file

Input Pipes n Used to read multiple rows of data n Pipe must be opened before use n Pipe must be closed after use n GETPIPE command used to read records n STD and DB2 format input pipes n Server expects records in IXF format

The DB2 SQLDA Structure n Used with dynamic SQL SELECT statements n Partially filled in when DESCRIBE is executed n Describes the columns to be returned by a SELECT statement n User must supply pointers to data and null indicators

SQLDA Structure SQLTYPE SQLTYPE SQLLEN SQLLEN SQLDATA SQLDATA SQLIND SQLIND SQLNAME SQLNAME SQLDAID SQLDABC SQLDABC SQLN SQLN SQLD SQLD Column 1 information Column 2 information Column 3 information

The ViaSQL SQLDA Structure n Same format as the DB2 SQLDA n Partially filled in when DESCRIBE is executed n Describes the columns to be processed by an RSP n User must supply pointers to data and null indicators

DESCRIBE Processing n Makes RSP development easier n The Legacy Data Manager is used to create a Virtual Table definition n At execution time, the RSP issues DESCRIBE command to fill in the SQLDA

Stored Procedure Test Facility n Provides standalone test of RSP n Invoked via CICS SPTEST command n User specifies stored procedure name n Variables can be specified n Data and messages are displayed

More Information n Remote Stored Procedure Programmers Guide and Reference n Sample RSPs on our website n Sample RSPs distributed with ViaSQL software