Ims user group ims explorer lab - Columbus RUG September 2012
Upcoming SlideShare
Loading in...5
×
 

Ims user group ims explorer lab - Columbus RUG September 2012

on

  • 424 views

 

Statistics

Views

Total Views
424
Slideshare-icon Views on SlideShare
424
Embed Views
0

Actions

Likes
0
Downloads
10
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Ims user group ims explorer lab - Columbus RUG September 2012 Ims user group ims explorer lab - Columbus RUG September 2012 Document Transcript

    • SeMIUG and COIUG IMS User Group Meetings – Fall 2012IMS CSL: The IMS Common Service Layer What is it? Why should I set it up? What is it good for? How does IMS use it?IMS SPOC: The IMS Single Point Of Control What is it? What are "Type 2 Commands" ? How will new commands help me manage and operate my IMS systems?IMS Open Database, ODBM & IMS Explorer What is it? Why should I set it up? What is it good for? How can I use it?IMS Enterprise Suite Explorer for Development Bring your Laptop! You will download & install the IMS Explorer! View and modify DBDs/PSBs ! Experiment with SQL to access IMS Databases ! IMS Enterprise Suite Explorer for Development V2.1.1.3 (Available June 22, 2012) A no-charge tool that enables you to perform application and database development tasks from an Eclipse based platform. • Quickly and easily model, display, and edit IMS database and program definitions. • Use rich GUI controls and contextual help. • Simplify segment mapping. • Securely and intuitively view and edit z/OS data sets and z/OS Unix files, submit JCL, and view output and job logs. • Gain a relational view of IMS data. • Build SQL statements to use with IMS data. • Integrate with IMS catalog and simplify your application tasks even more. • Exploit new structure and array types that are accessible thanks to IMS catalog support. • IMS Explorer runs on Windows systems and supports cross-product integration (shell-sharing) with IBM Rational Developer for System z, IBM Data Studio, and IBM Problem Determination Tools plug-ins for Eclipse.N.B. For this Lab, copy the entire “IMS User Group Lab” directory from one of theroaming Flash Memory sticks to your laptop. This directory contains 2 zip files andvarious documentation files. We will install the standalone version of Explorer. 1. Plug the Flash Memory stick into your laptop 2. Go to Windows Explorer on your laptop 3. Select the Removable Disk (D:) and expand 4. Click the IMS directory 5. CRTL-C 6. Select the laptop Local Disk (C:) and expand 7. Click the C: directory or a C:xxxx directory 8. CTRL-V
    • Start at the IBM IMS Home Page: www.ibm.com/ims Components - IMS SOA Integration Suite
    • Select the “IMS Enterprise Suite download web site” link
    • IMS Enterprise Suite downloads – you need an “IBM ID” to Sign-in and download IBM software
    • IMS Enterprise Suite downloads – recommend you use 1) “Download using Download Director”, 2)“Select all files” and 3) click “Download Now”
    • While waiting for downloads to complete…check out the online IMS Explorer documentation:The IMS Explorer documentation can be found in the IBM IM InfoCenter:http://publib.boulder.ibm.com/infocenter/dzichelp/v2r2/topic/com.ibm.ims.explorer21.doc/wb_container_imsexplorer.htmThe IMS Explorer installation instructions can be found in the IBM IM InfoCenter:http://publib.boulder.ibm.com/infocenter/dzichelp/v2r2/topic/com.ibm.ims.explorer21.doc/wb_installoverview.htmThe latest IMS Explorer “README” containing a cumulative list of changes to components, relatedinstallation information, and known issues and workarounds can be found at:https://www-304.ibm.com/support/docview.wss?uid=swg27021802After the downloads are completed…follow steps A & B: A. Install the Installation Manager for Windows V1.4.4 agent.installer.win32.win32.x86_1.4.4.zip (113 MB) - installer package B. Install IMS Enterprise Suite Explorer for Development V2.1.1.3 1. IMSExplorer2113.zip (700 MB) - Standalone version or 2. IMSExplorer_SS2113.zip (33MB) - RDz Shell-Sharing version i. Install Rational Developer for System z V8.0.1 and upgrade to V8.0.3 1) RDz803IMS_Installation.txt (2KB) 2) RDz801IMS_clientInstall.zip (2GB) C. Experiment with IMS Enterprise Suite Explorer for Development 1. Visualization of IMS Database Segment Heirarchy 2. Modification of DBDs and PSBs 3. Creation of Metadata 4. Connecting to IMS Control Region 5. SQL Access to IMS DBs 6. Accessing Metadata in the IMS Catalog============================================================================STEP A: Install IBM Installation Manager for Windows V1.4.4IBM Installation Manager helps you install, update, modify, roll back, and uninstall packageson your computer. Use this version to install Installation Manager or to update a currentinstallation of one of these versions of Installation Manager: 1.4.x, 1.3.x, 1.2.x, and 1.1.x.1. Locate the Installation Manager for Windows installer package agent.installer.win32.win32.x86_1.4.4.zip2. Extract the compressed file to a directory3. Install using the Installation Manager user interface a. Open the directory where you extracted the compressed file b. Double click the install.exe file c. Follow the installer wizard pages to install Installation ManagerFull installation instructions for Installation Manager are in file “IBM Installation Manager V1.4.4.pdf” or on the web:http://www-01.ibm.com/support/docview.wss?uid=swg24029226
    • After the install is complete, search for Installation Manager updates (requires Internet access):1. Start Installation Manager2. Verify that updates are enabled Click File > Preferences > Updates and select Search for Installation Manager update3. Verify that service repositories are searched. Click File > Preferences > Repositories and select Search service repositories during installation and updates4. Click OK5. On the main page of the Installation Manager, click UpdateSTEP B: Install IBM IMS Enterprise Suite Explorer for Development V2.1.1.3IMS Explorer combines a graphical front end with an integrated development environment(IDE) built on the Eclipse platform, an open software development environment that provides astandard GUI-based framework. As a result, IMS Explorer can be integrated with other Eclipse-based plug-in tools—such as IBM Rational® Developer for System z and IBM Data Studio—tosupport the entire IMS application development cycle. Moreover, developers familiar withEclipse-based tools can use their existing skills to immediately start manipulating IMS datathrough IMS Explorer.Next, use Installation Manager to install the standalone version of Explorer: 1. Add a repository and specify the location, including the zip file name where the IMS Explorer repository file IMSExplorer2113.zip resides Click “File” -> “Preferences” -> “Repository” -> “Add Repository” -> “Browse” 2. Click OK to add the repository location to the list 3. Click OK to go back to the IBM Installation Manager main screen 4. Click Install
    • 5. Select the check box for IMS Enterprise Suite Explorer for Development, click Next a. If the version of IBM Installation Manager that you have installed does not meet the minimum requirement, you are prompted to Update the IBM Installation Manager. i. Click Yes to install the updated version ii. When update completed, click OK, and the new version of the IBM Installation Manager is automatically restarted iii. Go back to Step 1 to install IMS Explorer6. Accept the terms in the license agreement, then click Next7. For installation location, select Create a new package group, and specify the IMS Explorer installation directory.8. For languages, IMS Explorer is available only in English, click Next9. Click Next to go to the Summary page10. Click Install. When the installation process completes, click Finish11. Verify IMS Explorer installation a. Open Explorer, click Start > All Programs > IMS Enterprise Suite Explorer for Development > IMS Enterprise Suite Explorer for Development b. Select a name for your workspace directory, click OK12. Review the WELCOME panel, click Close this window…
    • Welcome Window opens and offers: • IMS Explorer Overview & IMS Explorer Project Oveview • Migration of DLIModel Utility Plug-In Projects • IMS Web Resources • Tutorials via YouTube • Sample DBDs (C:Program FilesIBMIMS Enterprise Suite Explorer for DevelopmentIMS Explorer samples) • First Steps – Create an Explorer Project, Create/Edit PSBs & PCBs, Edit DBDs & Visualize IMS DBs, Access IMS DBs with SQL (read, replace, insert, delete segments)
    • STEP C: Experiment with IMS Enterprise Suite Explorer Open the IMS Explorer perspective by clicking Window > Open Perspective > Other > IMS Explorer (default) > OK 1. Create an IMS Explorer Project 2. Import IMS resources a. from your local file system b. from z/OS system 3. Generate Java Metadata classes 4. Import Data Structures (only if Shell-Sharing with RDz - skip this for User Group Lab) 5. Visualize IMS Databases Using IMS DBD Editor a. basic edit view b. related DBDs view c. logical DBD modeler view (Secondary Indexes and Logical Relationships) 6. Edit or add fields to DBDs and PSBs 7. Connect to an IMS DB System For SQL Access 8. Access IMS DBs using SQL 9. Accessing Metadata in the IMS CatalogCreate an IMS Explorer Project in the IMS Explorer Perspective 1. From the main menu bar, click File > New > IMS Explorer Project 2. In the Project name field, type the name of your project 3. You can create the IMS Explorer project without importing any IMS resources, or you can import IMS resources into the new project a. Click Finish to create the project without importing any IMS resources; you can import IMS resources into your project at a later point b. Optionally, you could click Next to proceed to the wizard to import IMS resources into the new project (skip this for User Group Lab)Your new project is displayed in the Project Explorer view with a folder for the database descriptionfiles and a folder for the program definition files. You can now create or import the IMS resources thatyou need to plan, analyze, and make changes to your IMS databases.
    • Import IMS Resources Into an IMS Explorer Project (from your Local file system) and GenerateJava Metadata Classes 1. From the main menu bar, click File > Import > IMS > IMS Resources (You can also import IMS resources by right-clicking an existing project in the Project Explorer view, and clicking Import > IMS > IMS Resources) 2. In the Project name field, select the name of IMS Explorer project created earlier , click Next 3. In the Import IMS Resources wizard, select Local file system. Click Next
    • 4. Select the PSB and DBD files that you want to import from (for User Group Lab use C:Program FilesIBMIMS Enterprise Suite Explorer for DevelopmentIMS Explorer samples) a. To import PSB files, click Add PSB, select the PSB files, and click Open to select the files to import (for User Group Lab use DFSIVP1.txt) b. To import DBD files into the project, click Add DBD, select the DBD files, and click Open to select the files to import (for User Group Lab use AUTODB.DBD, AUTOLDB.DBD, EMPDB2.DBD, EMPLDB2.DBD) If the PSB file is valid, IMS Explorer searches for any DBD files that are referenced by the PSB in the same file directory or subfolder within the directory, and selects them to be imported into the project. If the imported PSB file references any DBDs that are not in the same file directory or subfolder within the directory as the PSB file or that have not been added explicitly, the missing DBDs are listed in the DBDs to import for selected PSBs or DBDs table. Click Add DBD to add the missing DBD files.
    • You can import any DBD into your project, even if it is not listed in the DBDs to import for selectedPSBs or DBDs table.If the imported DBD file references any DBDs that are not in the same file directory or subfolder withinthe directory as the DBD file or that have not been added explicitly, the missing DBDs are listed in theDBDs to import for selected PSBs or DBDs table. Click Add DBD to add the missing DBD files.
    • 5. Click Finish a. PSBs and DBDs source is imported and parsed b. IMS Program definition model generated for PSBs in the “PSB” folder c. IMS Database definition model generated for DBDs in the “DBD” folder d. IMS Universal Driver metadata generated for PCB DatabaseViewsVisualize IMS Databases Using IMS™ DBD EditorUsing IMS Explorer, you can visualize the structure of IMS™ databases. You can use the IMS DBDeditor to view the segment hierarchy for an IMS database and to edit the field attributes for asegment. You can use the IMS DBD editor to visualize the database structure of logical relationshipsand indexes. You can use the IMS DBD editor to plan and design database description changes tosupport application requirements. Basic Edit view mode This is the default mode when a database model is opened in the IMS DBD editor and is the only mode that allows editing. Shows a visual representation of a single physical or logical DBD, and the segment hierarchy of the database. For a logical DBD, the editor also shows concatenated segments. A concatenated segment represents segments from two
    • DBDs that are associated through a logical relationship. A concatenated segment can beaccessed by an application program as a segment in a physical DBD.• double click the IVPDB1.dbd name (look for Edit view icon ( ) or• right click the IVPDB1.dbd name > Open With > IMS DBD Editor• click on the DBD name IVPDB1, the Segment A1111111, and the various fields to see the “Properties” of each
    • Related DBDs view mode This mode shows the physical DBD, and other DBDs that it has logical relationships with. A logical relationship is graphically represented by an arrow from the bottom of the logical parent segment to the top of the logical child segment. • double click the DEALERDB.dbd name
    • • click the Related DBDs view icon ( ) Logical Database modeler view mode ( ) This mode shows the different data structures that are possible given the existing secondary indexes and logical relationships that are defined for a given DBD Secondary indexes: segments labeled as targets of a secondary index are defined in the DBD as secondary index target segments Logical relationships: segments labeled as logical child segments are part of a logical relationshipEdit or Add Fields in a DBD 1. From the IMS DBD editor, right-click the segment name that contains the physical DBD field(s) you want to add or edit and click Add, Edit, or Remove Field (use the MODEL segment in the DEALERDB DBD for the User Group Lab) a. the Add, Edit, or Remove Field wizard opens with the unmapped fields (fields that are not yet part of a map or fields that are common to all maps) displayed b. Optional: In the Add, Edit, or Remove Segment Maps wizard, select the segment map and map case that contains the field that you want to add or edit (do not update map data for the User Group Lab)
    • 2. Add a new physical DBD field or edit or delete an existing one. Click Finish
    • • Modify the <empty> field to assign a NAME and an Alias o double click the <empty> NAME cell• Click Next• Modify the NAME and Field name, the Alias and the data type• Click Next
    • • Click Finish • Click Finish3. At the IMS DBD Editor display, note the new “MYFLD” field in the MODEL segment
    • 4. To save the changes to your DBD, press Ctrl+S5. Review the DBD source code changes a. expand the DBD Source > expand the Generated Source b. double click DEALERDB to review the generated DBD source code
    • Edit or Add PCBs in a PSBYou can modify properties in PSBs and associated PCB statements by using the PSB summary pageand the IMS™ PCB editor in IMS Explorer. 1. From the Project Explorer, open the DFSIVP1 PSB by double-clicking the program definition model - the program definition model has a .psb file extension
    • 2. Edit the PSB and PCB statements that are associated with the DFSIVP1 PSB • Specifying an alternate PCB An alternate PCB statement describes an alternate message destination where a message can be sent when the destination of a message differs from the place where it was entered. Use the alternate PCB statement section of the PSB summary page to create or modify an alternate PCB statement. • Creating or modifying full-function or Fast Path database PCBs Use the full-function or Fast Path database PCB statement section of the PSB summary page to create or modify a full-function or Fast Path database PCB statement. • Creating or modifying GSAM database PCBs Generalized sequential access method (GSAM) databases are sequentially organized databases that are designed to be compatible with z/OS® data sets. Use the GSAM database PCB statement section of the PSB summary page to create or alter a GSAM database PCB statement. The GSAM database PCB statement defines a view that controls how application programs can access the GSAM database. • Specifying PSB generation properties Use the PSB generation statement section of the PSB summary page to specify property values for the PSBGEN statement, which describes the characteristics of an application program. • Specifying segment sensitivity You can use the IMS PCB editor to define which segments an application program is sensitive to in the database program communication block (PCB) for the hierarchy that contains those segments. An IMS application program can access only data to which it is sensitive. Segment sensitivity can prevent an application program from accessing all the segments in a particular hierarchy. The sensitivity tells IMS which segments in a hierarchy the program is allowed to access. • Specifying field sensitivity You can use the IMS PCB editor to define which fields an application program is sensitive to in the database program communication block (PCB) for the hierarchy that contains those fields. An IMS application program can access only data to which it is sensitive. Field sensitivity can prevent an application program from accessing all the fields in a particular hierarchy. The sensitivity tells IMS which fields in a hierarchy the program is allowed to access.3. To save your PSB and PCB modifications, type Ctrl + S. (If there are unsaved changes, an asterisk (*) is displayed in the PSB tab.) When you save changes in the PSB summary page or the IMS PCB editor, IMS Explorer generates a Java metadata (DLIDatabaseView) class for the PSB and a PSB source file. The generated Java metadata class is located in the Project Explorer, under a package named after the PSB name. You can use the Java metadata class to connect to an IMS database from the Data Source Explorer in IMS Explorer, or to develop Java applications for IMS. The generated PSB source file is located in the Project Explorer, under Project name > PSB Source > Imported source. To connect to an IMS™ database using the IMS Explorer, you must generate a Java metadata class that provides the application view of the IMS database specified by a program specification block (PSB) and its related Program Control Blocks (PCBs). A Java metadata class is also required to develop Java applications for IMS.4. Review the PSB source code changes a. expand the PSB Source > expand the Generated Source
    • b. double click DFSIVP1 to review the generated PSB source codeConnect to an IMS DB System For SQL Access First, IMS Connect, CSL, and ODBM tasks must be installed, configured, and running! 1. In the Data Source Explorer, right-click the Database Connections folder, and click New
    • 2. Select IMS as the database manager and the IMS Universal JDBC driver as the JDBC driver3. Enter the following connection Properties • Connection name: IMS LAB DB • Data Store: IMSB • Host: zserveros.demos.ibm.com • Port number: 7013 • User name: IMPOTxx • Password: IBM07POT4. Scroll down and enter the Metadata source • Local IMS Explorer project Project: UserGroupLab (or whatever you named your Project) PSB: DFSIVP15. Click Finish
    • Access IMS DBs Using SQL 1. In Data Source Explorer, expand Database Connections > expand IMS LAB DB and all sub-levels 2. Right click the A1111111 table, then click Data, then click Return All Rows or Sample Contents to retrieve sample data from the A1111111 segment in the IVPDB1 IMS DB
    • 3. In the SQL Results tab, several windows of information are returned from the call: a. SQL call Status b. Actual SQL call executed c. Results Set4. Click File > New > Other > Data > Data Development Project to create a Data Development Project to create/run custom SQL calls and scripts
    • 5. Click Next6. Click Next7. Click Finish8. In the Data Project Explorer, expand the UserGroupLabScripts project you created9. Create an SQL Script using the SQL and XQuery Script a. Right click the SQL Scripts folder > New > SQL or XQuery Script b. Enter a name for the Script (ie. INSERT)
    • c. Click Finish d. In the opened INSERT.sql window, key in your INSERT SQL values: e. INSERT INTO PCB01.A1111111 VALUES (‘1234567890’,’0987654321’,’0001112222’,’7777777’,’333’) i. Replace ‘1234567890’ with last name and ‘0987654321’ with first name ii. Replace ‘0001112222’ with phone #, ‘7777777’ with zipcode, and ‘333’ with filler value iii. If needed, look at the DBD for the A1111111 segment layout10. Create an SQL statement using the SQL Query Builder a. Right click the SQL Scripts folder > New > SQL or XQuery Script b. Enter a name for the Script (ie. SELECT) and choose the statement type c. Click Finish11. Right click in the middle window to add a table and use the pop-up menu12. Choose the table you want to SELECT data from (ie. PCB01.A1111111)
    • 13. Choose the fields in the table you want returned14. Right click in the SELECT.sql window > Run SQL a. Use CRTL-S to save your script15. Experiment with SELECT, INSERT, UPDATE, DELETE a. Please DELETE any data you add to the IVPDB1 database – Thank You!16. Take what you learned back to the office, open your IMS Explorer project and build a connection to your IMS Datastore. Try to access your IMS data with SQL.