OS/400 Distributed Database Programming V5R2

2y ago
30 Views
3 Downloads
1.50 MB
316 Pages
Last View : 25d ago
Last Download : 3m ago
Upload by : Troy Oden
Transcription

ERserveriSeriesDistributed Database ProgrammingVersion 5

ERserveriSeriesDistributed Database ProgrammingVersion 5

Copyright International Business Machines Corporation 1998, 2001, 2002. All rights reserved.US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contractwith IBM Corp.

ContentsAbout Distributed DatabaseProgramming . . . . . . . . . . . . viiWho should read this information. .What’s new in V5R2 in the DistributedProgramming book. . . . . . .Code disclaimer information . . . . . .Database. . . . . . .Backup and recovery for a distributed relationaldatabase . . . . . . . . . . . . . . 26. viiChapter 3. Communications for aniSeries Distributed Relational Database. 27. vii. viiChapter 1. Distributed RelationalDatabase and the iSeries server . . . . 1 Distributed relational database processing . . . . 1Remote unit of work. . . . . . . . . . . 4Distributed unit of work . . . . . . . . . 5Other distributed relational database terms andconcepts . . . . . . . . . . . . . . . 6Distributed Relational Database Architecture Support 7DRDA and CDRA support. . . . . . . . . . 8Character conversion with CDRA . . . . . . 8Application requester driver programs. . . . . . 9Distributed relational database on the iSeries server 10Managing an iSeries Distributed Relational Database 11Example: Spiffy Corporation distributed relationaldatabase . . . . . . . . . . . . . . . 12Spiffy Organization and system profile . . . . 12Business processes of the Spiffy CorporationAutomobile Service . . . . . . . . . . . 14Distributed Relational Database administrationfor the Spiffy Corporation . . . . . . . . 14Chapter 2. Planning and Design forDistributed Relational Database . . . . 17Identifying your needs and expectations for adistributed relational database . . . . . . . .Data needs for distributed relational databasesDistributed relational database capabilities . . .Goals and directions for a distributed relationaldatabase . . . . . . . . . . . . . .Designing the application, network, and data for adistributed relational database . . . . . . . .Tips: Designing distributed relational databaseapplications . . . . . . . . . . . . .Network considerations for a distributedrelational database . . . . . . . . . . .Data considerations for a distributed relationaldatabase . . . . . . . . . . . . . .Developing a management strategy for a distributedrelational database . . . . . . . . . . . .General operations for a distributed relationaldatabase . . . . . . . . . . . . . .Security considerations for a distributedrelational database . . . . . . . . . . .Accounting for a distributed relational databaseProblem analysis for a distributed relationaldatabase . . . . . . . . . . . . . . Copyright IBM Corp. 1998, 2001, 200217171818202021 Communications tools for DRDA implementationAPPC/APPN for a distributed relationaldatabase . . . . . . . . . . . . .Using DDM and distributed relational databaseAlert support for a distributed relationaldatabase . . . . . . . . . . . . .Distributed relational database communicationsnetwork considerations . . . . . . . . .Configuring communications for a distributedrelational database . . . . . . . . . . .Configuring a communications network forAPPC . . . . . . . . . . . . . .Example: APPN configuration for a distributedrelational database . . . . . . . . . .Configuring alert support for a distributedrelational database . . . . . . . . . .Example: Configuration for alert support for adistributed relational database . . . . . .Configuring a communications network forTCP/IP . . . . . . . . . . . . . .Configuring communications over OptiConnect27. 2828. 29. 30. 30. 31. 33. 40. 42. 4344Chapter 4. Security for an iSeriesDistributed Relational Database . . . . 45Elements of distributed relational database securityElements of DRDA Security in an APPC networkDRDA application server (AS) security in anAPPC network . . . . . . . . . . . .Elements of DDM/DRDA Security using TCP/IPDRDA server access control exit programs . . .Object-related security for DRDA . . . . . .Authority to distributed relational databaseobjects . . . . . . . . . . . . . . .Programs that run under adopted authority for adistributed relational database . . . . . . .Protection strategies in a Distributed RelationalDatabase . . . . . . . . . . . . . . .46475052616566676822Chapter 5. Setting Up an iSeriesDistributed Relational Database . . . . 7122Work Management on the iSeries server . . . . .Setting up your work management environmentfor DRDA . . . . . . . . . . . . . .Considerations for setting up subsystems forAPPC . . . . . . . . . . . . . . .DRDA considerations with user relational databasesUsing the relational database directory . . . . .Working with the relational database directoryRelational database directory setup example . .22242525 72727375767782iii

Setting up DRDA security . . . . . . . . .Setting up the TCP/IP Server for DRDA. . . . .Setting up SQL Packages for Interactive SQL (ISQL)Setting up DDM files . . . . . . . . . . .Loading data into tables in a distributed relationaldatabase . . . . . . . . . . . . . . .Loading new data into the tables of a distributedrelational database . . . . . . . . . . .Moving data from one iSeries server to anotherMoving a database to an iSeries server from anon-iSeries server . . . . . . . . . . .Data redundancy in your distributed relationaldatabase network . . . . . . . . . . .84858586Chapter 8. Distributed RelationalDatabase Performance . . . . . . . 14387Improving distributed relational databaseperformance through the network . . . .Improving distributed relational databaseperformance through the server . . . . .Improving distributed relational databaseperformance through the database . . . .Deciding DRDA data location . . . . .Factors that Affect Blocking for DRDA . .Factors that affect the size of DRDA queryblocks . . . . . . . . . . . . .878894Chapter 6. Distributed RelationalDatabase Administration and OperationTasks . . . . . . . . . . . . . . . 97Monitoring relational database activity . . . . . 97Working with jobs in a distributed relationaldatabase . . . . . . . . . . . . . . 98Working with user jobs in a distributed relationaldatabase . . . . . . . . . . . . . . 98Working with active jobs in a distributedrelational database. . . . . . . . . . . 100Working with commitment definitions in adistributed relational database . . . . . . . 101Tracking request information with the job log ofa distributed relational database . . . . . . 102Locating distributed relational database jobs . . 102Operating remote iSeries servers . . . . . . . 104Controlling DDM conversations . . . . . . . 106Reclaiming DDM resources . . . . . . . . 107Displaying objects used by programs . . . . . 108Example: Display Program Reference . . . . 109Dropping a collection from a distributed relationaldatabase . . . . . . . . . . . . . . . 110Job accounting in a distributed relational database 111Managing the TCP/IP server . . . . . . . . 112DRDA TCP/IP server terminology . . . . . 113TCP/IP communication support concepts forDDM . . . . . . . . . . . . . . . 113DRDA/DDM server jobs . . . . . . . . 116Configure the DDM server job subsystem . . . 119Identifying server jobs . . . . . . . . . 120Auditing the relational database directory . . . . 122ivOS/400 Distributed Database Programming V5R2. 125. 126. 143. 144. 145. 145. 145. 148Chapter 9. Handling DistributedRelational Database Problems . . . . 149Chapter 7. Data Availability andProtection for a Distributed RelationalDatabase . . . . . . . . . . . . . 125Recovery support for a distributed relationaldatabase . . . . . . . . . . . . . .Data recovery after disk failures for distributedrelational databases . . . . . . . . .Journal management for distributed relationaldatabases . . . . . . . . . . . . .Transaction recovery through commitmentcontrol . . . . . . . . . . . . .Save and restore processing for a distributedrelational database. . . . . . . . . .Network redundancy issues for a distributedrelational database. . . . . . . . . . . 140 iSeries Problem Handling Overview . . . . . .Isolating Distributed Relational Database ProblemsDRDA incorrect output problems . . . . . .Application does not complete in the expectedtime problems . . . . . . . . . . . .Working with distributed relational database usersCopy screen . . . . . . . . . . . . .Messages . . . . . . . . . . . . . .Handling program start request failures forAPPC . . . . . . . . . . . . . . .Handling connection request failures forTCP/IP . . . . . . . . . . . . . .Application problems. . . . . . . . . . .Listings . . . . . . . . . . . . . .SQLCODEs and SQLSTATEs . . . . . . .System and communications problems . . . . .iSeries problem log . . . . . . . . . .Alerts . . . . . . . . . . . . . . .Getting data to report a failure . . . . . . .Printing a job log . . . . . . . . . . .Finding job logs from TCP/IP server prestartjobs . . . . . . . . . . . . . . .Printing the product activity log . . . . . .Trace job . . . . . . . . . . . . . .Communications trace . . . . . . . . .Finding First-Failure Data Capture (FFDC) dataStarting a service job to diagnose application serverproblems . . . . . . . . . . . . . . .Service jobs for APPC servers . . . . . . .Creating your own TPN and SettingQCNTSRVC . . . . . . . . . . . . .Service jobs for TCP/IP servers . . . . . .QRWOPTIONS Data Area Usage . . . . . 77177178179179182183183184185186. 127Chapter 10. Writing DistributedRelational Database Applications . . . 189. 130Programming considerations for a DistributedRelational Database application . . . . . . .Naming distributed relational database objectsConnecting to a Distributed Relational DatabaseSQL Specific to distributed relational databaseand SQL CALL . . . . . . . . . . . . 134. 138190190191200

Ending DRDA units of work . . . . . . .Coded Character Set Identifier (CCSID) . . .Other DRDA data conversion . . . . . . .DDM files and SQL . . . . . . . . . .Preparing distributed relational database programsPrecompiling programs with SQL statementsCompiling an application program . . . . .Binding an application . . . . . . . . .Testing and debugging . . . . . . . . .Working with SQL packages . . . . . . . .Using the Create SQL Package (CRTSQLPKG)command . . . . . . . . . . . . .SQL package management . . . . . . . .Delete SQL Package (DLTSQLPKG) commandSQL DROP PACKAGE statement . . . . . x A. Application ProgrammingExamples . . . . . . . . . . . . . :Creating a collection and tablesInserting data into the tables .RPG Program . . . . . .COBOL Program . . . . .C Program . . . . . . .Program Output . . . . .224225230239246252 How do you interpret an SQLCODE and theassociated tokens reported in a DBM SQL0969Nerror message? . . . . . . . . . . . .How can host variable type in WHERE clausesaffect performance? . . . . . . . . . .Can I use a library list for resolving unqualifiedtable and view names? . . . . . . . . .Can a user of DB2 Connect specify that theNLSS sort sequence table of the DRDA job onthe iSeries server be used instead of the usualEBCDIC sequence? . . . . . . . . . .Other tips for interoperating with workstationsusing DB2 Connect and DB2 UDB . . . . . .258259259260261Appendix C. Interpreting Trace Joband FFDC Data. . . . . . . . . . . 265Interpreting data entries for the RW component oftrace job . . . . . . . . . . . . . .Example: Analyzing the RW trace data . . .Description of RW trace points . . . . .First-Failure Data Capture (FFDC) . . . . .An FFDC Dump . . . . . . . . . .FFDC Dump Output Description . . . . .DDM Error Codes . . . . . . . . . .265266267270271274279Appendix B. Cross-Platform AccessUsing DRDA . . . . . . . . . . . . 253Appendix D. Glossary . . . . . . . . 283CCSID considerations . . . . . . . . . .iSeries server value QCCSID . . . . . . .CCSID conversion considerations for DB2 UDBfor z/OS and DB2 UDB server for VM DatabaseManagers. . . . . . . . . . . . . .Interactive SQL and Query Management setup onunlike application servers . . . . . . . . .FAQs from users of DB2 Connect. . . . . . .Do iSeries files have to be journaled? . . . .When will query data be blocked for betterperformance? . . . . . . . . . . . .Is the DB2 UDB Query Manager and SQLDevelopment Kit product needed for collectionand table creation? . . . . . . . . . .Bibliography . . . . . . . . . . . . 291253254255255256257iSeries server Information . . . . . .Distributed Relational Database Library .Other IBM Distributed Relational DatabasePlatform Libraries . . . . . . . . .Architecture Books . . . . . . . .Redbooks. . . . . . . . . . . . 291. 292. 293. 294. 294Index . . . . . . . . . . . . . . . 295257258Contentsv

viOS/400 Distributed Database Programming V5R2

About Distributed Database ProgrammingDistributed Database Programming describes the distributed relational databasemanagement portion of the Operating System/400 (OS/400) licensed program.Distributed relational database management provides applications with access todata that is external to the application and typically located across a network ofcomputers.For more information about this guide, see the following topics:v Who should read this informationv What’s new in V5R2 in the Distributed Database Programming bookv Code disclaimer informationThen, to get started, see Distributed Relational Database and the iSeries server forinformation on processing, supporting, programming, and managing an iSeriesDistributed Relational Database.Who should read this informationThis information is intended primarily for application programmers responsible forthe development, administration, and support of a distributed relational databaseon one or more iSeries servers. Application programmers who are not familiar withthe iSeries database can also get a view of the total range of database supportprovided by the OS/400 operating system. Application programmers may use thisinformation to see the server context in which distributed relational databaseapplications run.Before using this information, you should be familiar with general programmingconcepts and terminology, and have a general understanding of the iSeries serverand the OS/400 operating system.What’s new in V5R2 in the Distributed Database Programming book This release of the information includes the following updates:v “Kerberos Source Configuration” on page 56v “Connection security protocols for DDM/DRDA” on page 53v “DRDA Connect Authorization Failure” on page 162v “QRWOPTIONS Data Area Usage” on page 186v “Elements of DDM/DRDA Security using TCP/IP” on page 52v “SQL CALL statement (Stored Procedures)” on page 201v “Distributed unit of work” on page 5Code disclaimer informationThis document contains programming examples.IBM grants you a nonexclusive copyright license to use all programming codeexamples from which you can generate similar function tailored to your ownspecific needs Copyright IBM Corp. 1998, 2001, 2002vii

All sample code is provided by IBM for illustrative purposes only. These exampleshave not been thoroughly tested under all conditions. IBM, therefore, cannotguarantee or imply reliability, serviceability, or function of these programs.All programs contained herein are provided to you ″AS IS″ without any warrantiesof any kind. The implied warranties of non-infringement, merchantability andfitness for a particular purpose are expressly disclaimed.viiiOS/400 Distributed Database Programming V5R2

Chapter 1. Distributed Relational Database and the iSeriesserverDistributed relational database support on the iSeries server consists of animplementation of IBM* Distributed Relational Database Architecture* (DRDA*)and integration of other SQL clients by use of Application Requester Driver (ARD)programs. The Operating System/400 (OS/400) and the DB2 UDB for iSeriesQuery Manager and SQL Development Kit combine to provide this support.This chapter describes distributed relational database and how it is used on theiSeries server. It defines some general concepts of distributed relational databasethat are explained in the following topics:v Distributed relational database processingv Distributed Relational Database Architecture Supportv DRDA and CDRA supportv Application requester driver programsv Distributed relational database on the iSeries serverv Managing an iSeries Distributed Relational DatabaseIn addition to these topics, an Example: Spiffy Corporation distributed relationaldatabase is described. This fictional company uses the iSeries server in adistributed relational database application program. This sample of the SpiffyCorporation forms the background for all examples used in this manual.Distributed relational database processingA relational database is a set of data stored in one or more tables in a computer. Atable is a two-dimensional arrangement of data consisting of horizontal rows andvertical columns as shown in Table 1. Each row contains a sequence of values, onefor each column of the table. A column has a name and contains a particular datatype (for example, character, decimal, or integer).Table 1. A Typical Relational Soccer ballACME307Tables can be defined and accessed in several ways on the server. One way todescribe and access tables on the server is to use a language like Structured QueryLanguage (SQL). SQL is the standard IBM database language and provides thenecessary consistency to enable distributed data processing across different servers.Another way to describe and access tables on the server is to describe physical andlogical files using data description specifications (DDS) and access tables using fileinterfaces (for example, read and write high-level language statements). Copyright IBM Corp. 1998, 2001, 20021

SQL uses different terminology from that used on the iSeries server. For most SQLobjects there is a corresponding server object on the iSeries server. Table 2 showsthe relationship between SQL relational database terms and iSeries server terms. Table 2. Relationship of SQL Terms to System Terms SQL TermSystem TermRelational Database. A database thatcan be perceived as a set of tables andcan be manipulated in accordance withthe relational model of data. There arethree types of relational databases auser can access from an iSeries server,as listed under the system termcolumn. For more information, see theRelational Database topic in the iSeriesInformation Center.System Relational Database, or SystemDatabase. All the database objects that exist ondisk attached to the iSeries server that are notstored on independent auxiliary storage pools.User Relational Database, or User Database. Allthe database objects that exist in a singleindependent auxiliary storage pool group alongwith those database objects that are not stored onindependent auxiliary storage pools . Note: As ofV5R2, an iSeries server can be host to multiplerelational databases if independent auxiliarystorage pools are configured on the server. Therewill always be one system relational database,and there can be one or more user relationaldatabases. Each user database includes all theobjects in the system database. Note: The usershould be aware, however, that from acommitment control point of view, the systemdatabase is treated as a separate database, evenwhen from an SQL point of view, it is viewed asbeing included within a user database. For moreinformation, see the Transactions andcommitment control topic in the iSeriesInformation Center.Remote Relational Database, or RemoteDatabase. A database that resides on an iSeries oranother server that can be accessed remotely.Schema. Consists of a library, a journal, Libra

Distributed Database Programming describes the distributed relational database management portion of the Operating System/400 (OS/400) licensed program. Distributed relational database

Related Documents:

600 x 300 350 1260 50 6 14 600 x 300 669 2409 50 21 9 600 x 300 1137 4094 50 60 6 600 x 300 1750 6300 50 142 5 400 x 400 400 1440 50 9 12 400 x 400 674 2425 50 27 8 400 x 400 1170 4212 50 80 6 400 x 400 1750 6300 50 179 4 500 x 400 360 1296 50 5 15 500 x 400 715 2574 50 19 9 500 x 400 1330 4787 50 66 6 500 x 400 1800 6480 50 122 5 600 x 400 450 1620 50 5 15 600 x 400 958 3448 50 24 9 600 x 400 .

Distributed Database Design Distributed Directory/Catalogue Mgmt Distributed Query Processing and Optimization Distributed Transaction Mgmt -Distributed Concurreny Control -Distributed Deadlock Mgmt -Distributed Recovery Mgmt influences query processing directory management distributed DB design reliability (log) concurrency control (lock)

Distributed Database Cont 12 A distributed database (DDB) is a collection of multiple, logically interrelated databases distributed over a computer network. In a distributed database system, the database is stored on several computers. Data management is decentralized but act as if they are centralized. A distributed database system consists of loosely coupled

250 250 300 300 300 300 300 400 400 400 400 400 400 400 400 400 400 400 500 500 500 500 . Stainless steel enclosure for IP66/NEMA-4X Made of stainless steel up to 2mm thickness, 316L grade or equivalent . chemical or food industries and places where hygiene is necessary Highly polished SS

POWERSTAR HQI-T 400/N 400 W E40 42 000 lm MASTER HPI-T Plus 400W/645 400 W E40 35 000 lm RLF/400 HST VIALOX NAV-T 400 SUPER 4Y 400 W E40 56 500 lm SON-T Comfort 400W/621 400 W E40 38 000 lm VIALOX NAV-T 400 4Y 400 W E40 48 000 lm VIALOX NAV-T 400 400 W E40 48 000 lm RLF 500 IQT - - - - HalogenA IDE 500 W E40 10 250 lm RLF 300 IQL

Latest Cisco exams,latest 400-051 dumps,400-051 pdf,400-051 vce,400-051 dumps,400-051 exam questions,400-051 new questions,400-051 actual tests,400-051 practice tests,400-051 real exam questions Created Date: 9/1/2021 8:59:02 PM

SR333HD Max-E-Therm 333 BTU Heavy Duty Heater 333 138 SR400NA Max-E-Therm 400 BTU Natural Gas Heater 400 138 SR400LP Max-E-Therm 400 BTU Propane Gas Heater 400 138 SR400HD Max-E-Therm 400 BTU Heavy Duty Heater 400 138 460763 Max-E-Therm 400 BTU ASME NA 400 149 460764 Max-E-Therm 400 BTU ASME LP 400

Application of Silicon Carbide in Abrasive Water Jet Machining Ahsan Ali Khan and Mohammad Yeakub Ali International Islamic University Malaysia Malaysia 1. Introduction Silicon carbide (SiC) is a compound consisting of silicon and carbon. It is also known as carborundum. SiC is used as an abrasive ma terial after it was mass produced in 1893. The credit of mass production of SiC goes to Ed .