ims users group - fundi.com · ims users group [email protected] ... adabas db2 vsam ims internet/...

39
The Right “Change” SQL-Based Middleware Mike McKee CONNX Solutions IMS Users Group [email protected] http://www.connx.com

Upload: vuongkiet

Post on 10-Apr-2018

218 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

The Right “Change”

SQL-Based Middleware

Mike McKee

CONNX Solutions

IMS Users Group

[email protected]

http://www.connx.com

Page 2: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

What was the most “overused” word in 2008 Election?

Maverick

My Friends

Joe the Plumber

Historic

Change

Page 3: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Did you select “Change”?

Gartner analyst says

“People resistant to change will not survive

changes to the industry”

Page 4: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

And Yet …

Legacy Systems still very much in existence

today, and in most of Fortune 1000

companies

– DB2

– IMS

– VSAM

– ADABAS

Page 5: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

IMS Facts

90% of Fortune 1000 companies use IMS.

More than 3 trillion dollars of transactions go

through IMS in a single day.

Clients that run IMS have exceeded a

workload of 100 million transactions per day.

Taken from IBM Systems Magazine,

“Standing the Test of Time”, April 2008

Page 6: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Is IMS too old, and do we need to “change”

Steve Tockey, author of “Return on Software”

suggests that their comes a point in time

when costs to maintain a system (or asset)

becomes too costly, and analysis should be

made on whether to “retire” the system.

Main reasons Tockey states are

– Deterioration

– Obsolescence

Page 7: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Deterioration and Obsolescence

Deterioration

– Software does not deteriorate (machines might)

Obsolescence

– Changes in environment or requirements that

make it difficult or impossible to complete the

task.

Page 8: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Replacement analysis

This is based on looking at viable options

and see if they are “better” economic

solutions than the current solution. It is

primarily based on costs/income.

Is a more modern database/”newer”

technology more viable than IMS or other

legacy solutions?

Page 9: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Different opinions, but Middleware provides a proven way to extend life of legacy systems.

Middleware attempts to provide value to

legacy databases by creating additional

components that bridge older technologies

with new technologies.

SQL Based Middleware might be worth

considering, as many standards/products

support SQL.

Page 10: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

SQL Based Middleware

Enables “legacy” data (e.g. IMS) to be

accessed through newer

standards/technologies through SQL

Commands.

Attempts to make “IMS” or other legacy data

appear as a “relational” database.

May eliminate/postpone the need to migrate

because there middleware provides tools to

bridge legacy to newer technology.

Page 11: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Some Characteristics of SQL Based Middleware (SBM)

Supports ANSI SQL

Has repository for meta data that makes up

the Data Sources that it supports

Supports interface standards such as:

– ODBC

– JDBC

– OLEDB

– .NET

Page 12: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Review of Last Month’s architecture(WebSphere perspective)

Page 13: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Architecture of a SBM

Normally most SBM’s have a Client/Server

Architecture.

The Client module (The SQL Engine) resides

on a non-mainframe (PC, Linux Box, Web

Server).

The Server module resides on a mainframe,

or an a machine in which the data resides.

Page 14: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Diagram of Architecture

Virtual Database

SBM

(Server)

SBM

(Client)

ADABAS

DB2

VSAM

IMS

Internet/

Destop

Application

1. SQL

Request

3.

Processes

Request,

and returns

Data

2. Request

Data From

Server

ODBC/JDBC/

OLEDB/

DOTNET

SBM Architecture

Page 15: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

First Step – SQL Request

Applications/Services/Beans issues SQL

Requests through function calls in interfaces

such as:

– ODBC

– OLEDB

– JDBC

– .NET

Page 16: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Examples of SQL Applications

SSIS (Microsoft)

VB

Excel

SharePoint

Netbeans

Websphere

Many others …

Page 17: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Examples of SQL Interfaces

ODBC ODBC is an acronym for Open Data Base Connectivity. One of the most widely used

interfaces for Data Access. It is available on Window or Unix systems.

OLE DB Object Linking and Embedding Data Base interface. Usually invoked by “wrapper” API’s such

as ADO.NET/ADO.

JDBC Java Database Connectivity interface. Used for Java Development.

.NET

Provider

Interface for .NET Framework applications. Used for .NET Development (C#, VB.NET …)

Page 18: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Step 2 – Client Processing

Client evaluates SQL Request verifying it for

accuracy.

Develops execution plan based on the

common data dictionary (metadata) that

contains information about the tables,

columns, indexes.

Generates a RPC Call to the server.

Page 19: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Step 3 – Server gets control

Server analyzes the RPC call, and

determines if it is a select, insert, update,

delete call.

Server makes a call in the native language

(in IMS it is DL/I) to carry out the correct

operation.

Page 20: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Step 4 – Gives results back to Client

If it is a query, it would give results in the

form of data retrieved from the database.

If it was an update/delete/insert it would carry

out the operation, and let the client know how

many rows were processed.

While the processing seems simplistic, the

middleware deals with many “plumbing”

details such as data translation, date/time

issues, and threads/parallel processing.

Page 21: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

A “Virtual” Database

Many SBM’s can be described as a “virtual”

database. This means that they “abstract”

many of the data sources that might be

contained in the data dictionary.

For instance, a SBM might contain VSAM

files, IMS database, DB2 tables, Oracle

Tables, and a SQL Server database, and all

the details would be encapsulated in “private”

virtual database that clients would connect

to.

Page 22: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Virtual Database Diagram

Page 23: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Turning Heirarchial Relationships to Relational

Many critics of a SQL approach suggest that

it “impossible” to normalize Heirarchial

relationships.

Many legacy data in Cobol FD’s have arrays,

and sometimes arrays within arrays. In IMS

this is often also referred to as Segments.

While Xquery (Another way to access data)

allows for these types of data sources, these

data sources can also be turned into

relational sources.

Page 24: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Cobol FD becoming two relational tables

01 PAYMENT-RECORD.

05 ACCOUNTS.

10 MONTHLY-PAYMENT

PICTURE IS 9(6)V99

USAGE IS COMP-3

OCCURS 12 TIMES

10 CUSTOMER-NAME PIC X(30).

10 CUSTOMER-ADDRESS PIC X(80)

Customer Table

CustomerName CHAR(30)

CustomerAddress CHAR(80)

Monthly Payment Table

CustomerName CHAR(30)

MonthID INTEGER

PaymentAmount DOUBLE

COBOL FD Data Dictionary

Payment

VSAM File

Page 25: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Why is SQL Data Access important?

Standards, Standards, Standards

Widespread support by development

community.

Language is fairly simple to learn, yet

grammar is powerful.

Page 26: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

SQL Basics

SQL is consists of only 4 statements,

sometimes referred to as CRUD :

– Create - INSERT - to store new data

– Read - SELECT - to retrieve data

– Update - UPDATE - to change or modify data.

– Delete - DELETE - delete or remove data

Page 27: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Examples of SQL

Select order_id, customer_id, order_amt from orders where

order_id=’111222’

Joining two tables

Select order_id, customer_id, order_amt, customers.

customer_name from orders, customers where

order_id=’111222’ and customers.customer_id =

orders.customer_id;

Page 28: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Criteria for selecting a SBM Provider

Is the Data Source Supported?

Is the Hardware/OS Supported?

Performance – Is it close to the native speed

you get in your mainframe applications?

Data Type support – Some data types are

fairly complex (e.g. Date/Time). Are they

supported. Can it handle nested arrays?

Correct results – Are the results consistently

correct?

Page 29: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

More Criteria

Can Data Definition be easily imported into

the Repository (Data Dictionary)?

Evaluation – Is their support to assist you

during the evaluation process?

Security – Are they security enhancements?

Driver Interfaces – Is there support for

popular interfaces such as ODBC, OLEDB,

JDBC, and .NET?

Page 30: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

And Finally

Are there additional tools to complement the

SBM?

Page 31: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Where can I find a SBM?

A “Google” search on “ODBC”, “JDBC”,

“OLEDB”, “VSAM”, “Data Access”, “and IMS”

might provide a number of sites that link to a

SBM Provider. The following Web link by

noted database expert Ken North offers a list

of SBM Providers: http://www.sqlsummit.com/ODBCVend.htm

http://www.virtualims.com/tools.html

http://www.sqlsummit.com/JDBCVend.htm

Page 32: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Conclusion

A SBM can enhance the life of your legacy

system. By adding SQL Based Middleware

legacy databases, many new technologies

(Mashups, Web Services, Applets, Beans,

.NET, Web Applications) can be used to

provide value to your organization.

Page 33: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

IMS Demonstration

Importing IMS into a Dictionary

Generating a IMS Query through a Query

Tool

Page 34: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Importing IMS Database

Page 35: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Telling it where the server is located

Page 36: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Selecting the Database

Page 37: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Selecting the Tables

Page 38: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Performing a Query

Page 39: IMS Users Group - fundi.com · IMS Users Group mmckee@connx.com ... ADABAS DB2 VSAM IMS Internet/ Destop Application 1 . SQL Request 3. Processes ... SQL Basics SQL is consists

Questions?