Upload
dodang
View
263
Download
0
Embed Size (px)
Citation preview
Appendix A
Syntax Notation
Syntax Diagram This book makes use of syntax diagrams to describe the syntax of expressions. Syntax diagrams are read left to right, top to bollom.
.. -
.-
indicates the beginning of a statement
indicates the end of a statement
indicates that the statement is continued
indicates the continuation of the statement
Mandatory items cannot be branched around.
Example: . --mandatory
Loptional..J
If one of a number of mandatory items must be selected, then these items appear in a vertical stack .
Example: _----,mandatory1-.---
Lmandatory2..J
Multiple options appear in a vertical stack, one of the specified options may be selected.
App. Al SYNTAX NOTATION 185
E;r;ample :
There are two forms of repetition - either one or more options of a specified group of options may be selected (anyone option may be selected at most once). or one or more options of a specified group of options may be selected any number of time.
$elective repetition:
- kt;'"'~ opt 1 on2 Both option} and optionl may be selected not more than once.
Normal repetition:
- f....,Hoo, l Loptl0n2j n
Optionl and optionl may be selected any number of times, unless n is specified, in which case n specifies the maximum number of repetitions.
If the repeat arrow contains an item, then this item is mandatory for repetitions .
Example: _---0---------------------------, ___ . d t this option may be repeated ---:-,,-:---, this item is required for repet itions
An item written in upper case must be spelled e;r;actly as shown, an item written in lower case is replaced by a valid entry (described in the te;r;t). An underlined entry is the default value.
Exam~le : ---"PH·--,G--=~::-:-.,--~-
L;ill , The first item is mandatory and must be ALPHA ; the second item is optional, the default value is BElA.
If an item is wrinen italicised. then this is a parameter, the definition of which follows.
Example : _--logicaloperator __
186 SYNTAX NOTATION lApp. A
logicaloperator: .. 6:~ .. The "'ogicaloperator" parameter may be replaced by one of the optional values: AND or 011:.
A syntax diagram is fonned by combining the simple elements defined above.
Foot The sans serif font is used to depict commands. keywords or data set names.
Example: The QMF statement TSO DELETE is a command which invokes the TSO component DELElE.
Appendix B
Sal Data Areas
SQLCA (SQL Communication Area)
or SOLCA --------, SOltA-ID
SQLCABC
SQlCOOE
SOLERRM
8
2
• 8
88 SQLERRP SQlEJIRD 96 SOlERRD(1)
100 SQlERRD(2)
104 SQLEIIIIO(l)
10 SCLERRD (4)
8
11 SQLEIIIIO(5)
11 SQLEIIIIO ( 6) SQLWARN 12
12 $OLElCT
2
• 0
8
136
"SOLeA"
totaL length ( - 136)
SOL return code
length of error message
error mess lge t okens
Figure 8. 1 -SQLCA format
136 bytes
•
188 Sal DATA AREAS lApp. B
Table B.1 - SQLCA fields
Field name DaJa Iype Description
SQLCAIO CHARCS) SQLCA identifier: "SOlCA" SQLCABC INTEGER Jotallength OfSQLCA (136 bytes) SQLCOOE INTEGER SQL return code SQLERRM VARCHAR(70) SQL error message tokens SQLERRML length of error message Jokens SOLERRMC error message tokens (each separated by X'FF') SOLERRP CHAR{S) diagnostic information SOLERRO codes set by various DB2 components SOlERRD(1) INTEGER Relational Data System error code. SOlERRD(2) INTEGER Data Manager error code. SQLERRD(3) INTEGER number of rows affected by DELETE, INSERT or UPDATE
operation SQLERRD(4) FLOAT'" estimate of the amount of resources required by this
statement SQlERRD(5) INTEGER position of syntax error in PREPARE or
EXECUTE lMMEDlA TE slatement SQlERRD(6) INTEGER Buffer Manager error code SQUJARN warning flags SQlWARNO CHAR(l) blank if all the other warning flags are also blank,
otherwise OW" SOlWARN1 CHAR( 1) ' W" if value assigned to a host variable has been
truncated SQlWARN2 CHAR(1) OW" if null values have been eliminated from the search
SOLWARN3
SQl WARN4
SQLWARN5 SQl WARN6
SQLWARN7 SQlEXT
CHARCO
CHAR(1 )
CHAR(O CHAR(O
CHAR(1) CHARCS)
argument OW" if the number of columns returned is larger than the number of host variables specified ' W" if DELETE or UPDATE statement does not contain a SElECT clause ' W " if the statement is invalid · W· if a DATE or TIME value has been adjusted because it was invalid reserved reserved
'" The library definitions specify SQlERRD as being an array of 6 integer elements.
PLiI Definitions: DECLARE
1 SQLCA, 2 SQLCAtD CHAR(S), 2 SQLCABC FIXED(31) BINARY, 2 SQLCOOE FIXED(31) BINARY, 2 SQlERRM CHAR(70) VAR, 2 SOLERRP CHARCS), 2 SQLERRD(6) FIXEO(31) BINARY, 2 SQLWARN,
3 SQLWARNO CHAR(1), 3 SQLWARNl CHAR(1), 3 SOLWARN2 CHAR(1),
App. BJ
3 SOlWARM3 CKAR(1), 3 SOlWARN4 CKAR(1), 3 SOlWARN5 CHAR(l), 3 SOlWARN6 CHAR(l), 3 SQlWARN7 CKAR(l),
2 SOlEXT CKAR(8);
COBOL Definitions SOlCA . 05 SOlCAIO 05 SQlCABC 05 SOlCOOE 05 SOlERRM.
PIC X(B). PIC S9(9) COMP-4 . PIC S9(9) COMP-4 .
49 SQlERRMl PIC S9(4) COMp·4. 49 SOlERRMC PIC X(70).
05 SOlERRP PIC X(B). 05 SOlERRO OCCURS 6 TIMES
PIC S9(9) CC»IP·4. 05 SQlWARN.
10 SQlWARNO PIC X. 10 SQlWARM1 PIC X. 10 SQlWARN2 PIC X. 10 SOlWARN3 PIC X. 10 SOlWARN4 PIC X. 10 SOlWARN5 PIC X. 10 SOlWARN6 PIC X. 10 SQlWARN7 PIC X.
05 $QlEXT PIC X(B).
AssembleI' Definitions: SOlCA os Of SOlCAIO OS Cla ID SQlCABC os F SQlCOOE OS F SQLERRM OS H,Cl70 SQLERRP OS CLB
BYTE COONT RETURN COOE ERR MSG PARMS IMPL -OEPENOENT
SQlERRO OS 6F SQLWARN OS OC SOlWARNO OS C'W' SOlWARN1 OS C'W' SOlWARN2 OS C'W' SOlWARN3 OS C'W' SOlWARN4 OS C'W' SOL WARNS OS C'W' SQlWARN6 OS C'W' SQLWARN7 OS C'W' SOlEXT OS Cla
WARNING If ANY " WARNING " WARNING '" WARNING '" WARNING '" WARNING " WARNING " WARNING
FLAGS
Sal DATA AREAS 189
190 Sal DATA AREAS
C Language Definitions IIi fndef SOLCOOE struct sqlca
(unsi gned char l009 long short
uns i gned char i.XIsigned char
l009 unsigned char unsigned char
)
sqlcaid(81; sqlcaoc; sqlcode; sqlerrml; sqlerrmc(701; sqlerrp(8] ; sqlerrd(6); sqlwarn(8]; sqlext(81;
lIdefine SOLCOOE sqlca.sqlcode #define SOLWARNO sqlca.sqlwarn(Ol #define SOLWARN1 sqlca.sqlwarn(11 #define SOLWARNZ sqlca,sqlwarn[Zl #define SOLWARN3 sqlca,sqlwarn(3] #define SOLWARN4 sqlca.sqlwarn[4) #define SOLWARN5 sqlca,sqlwarn[5) #define SOLWARN6 sqlca.sqlwarn[6) #define SOLWARN7 sqlca . sqlwarn[7] lIendi f struct sql ca sqlca;
SQLDA (SQL Descriptor Area)
lApp. B
The SQLDA COntains data required for the embedded SQL DESCRIBE statement. The EXECUTE, FETCH, OPEH and PREPARE embedded SQL statements may also make use of the SQLDA. A sample SQLDA is shown in Figure B.3.
SQLDAIO
SQLOABC
SQLN
SOLD
SQLVAR
° • 12
r SOLDA
14
16
°1
"SQLOA"
total length (:m)
nurber of SQLVAR elements (:n)
nurber of collJMS
SQLVARl
,
44>--1 -----I
°1 SOLVARn
44LI ____ ---1
m bytes
•
App. Bl
SQLTYPE
SQlLEN
SQLOATA
SQUMO
SQlMAME
4
Or .SQLVAR dati type
2 ellterOll
4 length
address of host variable 8
address of indicator variable 2
length of name 4 -4
Figure 8.2 - SQLDA format
Table 8 .2 - SQLDA fields
Field name Data type Description
SQLDAID CHAR(8) SQlDA idemifier ~SQlOA ~ SQLOABC I NTEGER total length of SQlDA
SQL DATA AREAS 191
SQlN SMALLINT maximum number SQlVAR emries SQlO SMAlUNT current number of columns (SQLVAR entries)
SQLVAR describes each column:
Field name Data type Description SQLTYPE SMALLINT data type (see Table 8.3) SQLLEN SHAlllNT external length of data item SQlDATA poimer address of host variable SQLlND pointer address of indicator variable; a half-word containing a
negative value (usually -1) if the host variable is null SQLNAME VARCHAR(3D) name or label
192 Sal DATA AREAS
Table 8.3 - Data Iype codes
SOL TYPE data type
3841385
3881389
3921393
448/449
452/453
456/457
4601461
DATE fixed-length character sIring representation of a date TIME fixed-length character string representation of a time TIMESTAMP fixed-length character string representation of a timestamp VARCHAR varying-length character string CHAR fixed-length character string LONG VARCHAR varying-length long character string VARCHAR
lApp. 8
varying-length character string tenninated with the C-Ianguage null character
4641465
4681469
472/473
480/481
484 /485
496/497
5()()I501
504/505
VARGRAPHIC .. varying-length graphic string GRAPHIC· fixed-length graphic string LONG VARGRAPHtC • varying-length long graphic string FLOAT floating-pain! DECIMAL packed decimal INTEGER large binary integer SMALLJNT small binary integer (no data type) precision in byte I and scale in byte 2 .
• graphic means OBCS
Note on Table 8 .3: QMF control areas and records which store the null indicator explicitly use the same data type code (the even-numbered code) to identify both kinds of entry. The odd-numbered data type code indicates that nulls are allowed .
The standard SQLDA definitions for various host languages follow. Note: there is no standard library SQLDA definition for COBOL.
PLII SQLDA Definition: DECLARE
t SOLDA BASEoeSOLDAPTR), 2 SQLDAIO CHAR(6), 2 SOlDABC F t KED (31) B I NARY, 2 SQlN F{KEO(15 ) BINARY, 2 SOLO FtKED(t5) BINARY,
App. BJ
2 SOlVAR(SOlSIZE REFER(SOlN», 3 SQUYflE FIXEO(15) BINARY, 3 SQllEN FIXE0(15) BINARY, 3 SQlOATA POINTER, 3 SOllNO POINTER, 3 SQlNAME CHAR(30) VAR;
DECLARE SOlSIZE FIXEO(15) BINARY; DECLARE SQlOAPTR POINTER;
Assembler SQLDA Definition: SOlOA OSECT SOlOAIO os SOlOABC os SOlN os SOLD OS SQlVAR OS SOL VARN OSECT
CLB F H H OF
H
OH x x , ,
ID BYTE COONT TOTAL VARS PERTINENT VARS BEGIN VARS NTH VARIABLE TYflE CtoE NAME LENGTH OEC flRECISION DEC SCALE
SOL TYPE OS SOL lEN OS SOLflRCSN OS SOLSCALE OS SOlOA!A OS sallNO OS SQlNAME OS SQlVSIZ EOU
H, CL30 ·-SOlDATA
AOOR OF VAR AOOR OF INO DESCRIBE NAME
C Language SQLDA Definition: #ifndef SQLOASIZE struct sqlda
( unsigned char loo, short short struct
sqldaid[8); sq\dabc; sqln; sqld; sqlvar
(short sqltype; short sqllen;
unsigned char ·sqldata; short ·sql ind; struct sqlnarne
SQL DATA AREAS 193
(short length; unsigned char data[30l;
) sqlname; } sqlvar[1];
) ; #define SQLOASIZE(n) \
( sizeof(struct sqlda) + «n)-') • sizeof(struct sqlvar) ) lendi f
Example: The format of the SQLOA conslruCled for the selection:
SELECT fiNO, flNAME fROM PEII.S
with PNO OECIMAL(4,O) and value 3333 flHAME VARCHAR(24) and value ~ALflHA"
is shown in Figure B.3.
194 SOLDATAAREAS
o SOLDA r;;SOLOA" ::::J 8
SOLDA!D
SDlDABC
SClN
104 tonl leng
SOLD SClVAROl SOL TYPE
SOL lEN
SOlDATA
SOUNO
SOlNAME
2
4
6
2
2
2 ,
8
a
4
8
a
SOlVAR(21 60 SOL TYPE
SOL lEN
SOlDATA
SOUND
SOLNAME
2 6
64 .. 2 7
7 4
2 till ill i IfUI'I
2 current
4"
4 a
, 'NO
"8 24
5
PNAME
Figure B.3 - Sample SQLDA
I'lI..I1ber of coLums
I'IUItIer. of colum$
• 3333
• a
• 5 i' l , H 'i • a
RIB (Release Infonnation Block)
lApp. B
The DSNORIB macro produces a DSECT named RIB, whose structure is shown in Table B.4. In addition, the following code line containing the current DB2 release is generated:
R! BRVAl DC Cl3' vrlll' V = version r = release m :::: modification level
App. BJ SOL OAT A AREAS 195
Table B 4 -RIB fi elds
fie I d I'\aIIle dm typo descript i on
RIBCODE H IUB identifier
RIBTLEN H block leng th
RIBEVEC CL4 eye -c~tcher " RI8"
II[BC IO . c~nt identifier RIBECODE Cl4 envi ronnent code (5140) ) progr~m nunber RIBPCCllE Cl3 product code (KVIt) ) RIBFCCllE Cl2 future code RIBltEl 3CL 1 release identi f ier:
vers i on, release, mod ifi cation leve l
It I BCPTIt • address of ItIBCINFO (change level information array) R!BCNUHB HLl number of elements in RIBCIHFO
XL3 reserved KL16 reserved
Appendix C
Glossary
abend Word formed from abnormal end. A n abend occurs when a program does not terminate normally, i.e. because an error situation has been detected. Two forms of abend may occur: system and user. A system abend is detected by the operating system (e.g . program exception, system fa ilure). A user abend is issued by the program itself, e.g. the program has determined that it cannot continue processing. User abends should be avoided; in most cases a program completion code can be sel 10 indicate that processing fa iled.
alphabetic The set of characters containing the lower and upper case letters together with the three national characters: #, @ and $.
a lphanumeric The sel of alphabetic characters together with the ten numeric digits.
application plan Processing strategy for the embedded SQL statements; also known as plan . The application plan is identified by its unique application plan name. Every executable program that uses DB2 services requires an application plan. An application plan is fanned from DBRM members or packages.
Assembler Low-level programming language fo r low-level machinedependent programming tasks .
bind The processing performed on embedded SQL statements to produce control statements suitable for use in accessing the DB2 database.
App. C)
C
catalog
CICS
CLIST
COBOL
GLOSSARY 197
Modem mid-level programming language for low-level machine-independent programming tasks (Assembler replacemem). In the OB2 sense, the collection of system tables stored in the database. Customer Information Comrol System, monitor system to provide on-line transaction processing facilities for programs. Procedure consisting of TSQ commands and subcommands and control statements. CLiSTs are also known as command procedures. COmmon Business Oriented Language. High-level commercial programming language.
column A venical element of a table and is generally synonymous with a field in conventional data processing .
command procedure See CLIST and REXX procedure. commit The action of making changes to the database permanent . See
also revoke. compiler
CSP
cursor dataset database
DATABASE2 DBMS
DB2 DBCS
DBRM
DCLGEN
DD
A software component which convens a source program into an object module. Cross System Product. IBM application generator with interface to DB2 and ISPF.
In the DB2 contex.t, an internal pointer to a row in a table . IBM term for a file. A logically related set of named data elements. Database systems isolate users from the physical data storage. IBM relational data base, usually known as DB2.
Database Management System. A program to control the use of a database . DATABASE2. IBM relational data base . Double·Byte Character Set. A set of pairs of characters used to represent characters in Far-East languages (Chinese, Japanese, Korean, etc.) . Also known as graphic data in OB2.
Data Base Request Module . Each program using SQL services requires a OBRM to describe the logical access. The DBRM is produced by the OB2 precompiler and is used as input to the Bind processor. The bound OBRM is stored in the database. Dedarations generator. Creates program declarations for the elements in a OB2 table or view . Data Definition. The JCL statement used to assign the physical data (dataset, printer output class, etc.) to the logical dataset defined in the program. The ddname links the logical dataset to the JCL DO statement.
Dialog Manager !SPF component which administers dialogue facilities. Dialog Manager is usually synonymous with ISPF .
198 GLOSSARY
dialogue
DSORG
dynamic SQL
embedded SQL ESQL exec EXEC
file
FORTRAN
GDDM
GDF
graphic data halr·word
help em'ironment help panel
hosl language
host variable
IBM
lCU
lMS
indicator variable
lApp. C
Man-machine interaction using a terminal directly attached to compUier. Various levels of program systems (application program, terminal monitor program, etc.) control the dialogue. Dataset organisation. The organisation of information in a dataset . The creation of SQL statements at run-time. This means that authorisations and processing strategies must also be made at run-time. See ESQL. Embedded SQL. The SQL statements used in a program. Lowercase . A synonym for a REXX procedure. Uppercase . Execute program of procedure. The JCL statement used to invoke a program or lCL procedure. A collection of data ( = dataset). Also with regard to TSO it is equivalent to the JCL DO statement, filename is then equivalent to the ddname. FORmula TRANslation . High-level scientific programming language. Graphic Data Display Manager. ISM product consisting of basic subroutines for processing and displaying graphic data. Note: Graphic data here does not imply DBCS data. Graphics Data File . GDDM data format which contains processed graphs . See DBCS. A signed binary number which occupies 2 bytes. This is the same internal representation as a DSl SMALLlNT variable . Sub-environment used to provide on-line assistance . Panel which is used for display or data entry within the help environment. A programming language which can use embedded SQL statements, Le. a language for which a DBl precompiler exists . The following host languages are currently supported : Assembler, C, COBOL, FORTRAN, PUI. A variable contained in a program and used as DB2 data element. International Business Machines Corporation, supplier of 082 , CICS, ISPF, MVS, QMF, etc. licensed products. Interactive Chart Utility . A user-friendly dialogue interface to PGF for lhe processing of business (presentation) graphics . Infonnation Management System. IBM hierarchical database system. A host variable used 10 indicate whether the associated data value actually contains data or is null . The indicator variable
App . CI
interactive SQL ISPEXEC
ISPF
ISPLINK
ISPSTART JCL
library Linkage Editor
load module
locking
LRECL
member
MVS null
object module package panel
GLOSSARY 199
is set to contain a negative value (usually -I) , if the host value is null . SQL statements directly invoked (e .g. using OB21 or QMF). ISPF component which provides dialogue serv ices for CLlSTs and REXX procedures . Interactive System Productivity Facility, IBM programming system to provide dialogue facilities . ISPF requires TSO. ISPF is required by QMF and SPUFI. ISPF component which provides dialogue services for programs. ISPF component which invokes the ISPF environment. Job Control Language. The statements used to comrol the processing of a balch job. The principal JCL statemems are: DO and EXEC .
A partitioned dataset. IBM program to combine one or more object modules imo a load module. Machine-readable Linkage Editor output in a form suitable for loading into virtual storage for execution. The means of slOpping other users from accessing (read lock) or changing data (write lock), and is used to maintain data integrity. Logical record length. The number of characters fonning a record. Independem pan of a partitioned dataset. A member can be directly accessed and processed as if it were a sequential dataset. Multiple Virtual Systems operating system. For OB2, a special value indicating that this particular element (row-column) does not actually contain a value, it is not the same as 0 (for a numeric field) or blank (for a character field). See indicator variable. machine-readable compiler output. A non-executable plan that is associated with a program. Form with which data is to be displayed on a display terminal.
partitioned dataset A data set comprising of members. Each member can be
PGF
accessed directly by means of its (member) name. Program Development Facility, IBM dialogue utility package to assist the programmer in program development. PDF is an ISPF appl icat ion. Presemalion Graphics Feature. Library of routines using GDDM to create presentation (business) graphics. ICU is a dialogue interface to PGF.
200 GLOSSARY
PL/I
precompilation
profile pool
QBE
QMF query revoke
REXX
row
SAA
session
shared pool
source program
SPUFl
lApp. C
Modem high-level programming language combining many of the features of COBOL and FORTRAN.
The action of converting embedded SQL statements to statements which can be processed by the host language. The precompiler also produces a DBRM entry from the SQL statements . The pool of dialogue variables belonging to a panicular application. The profile pool is retained across ISPFiTSO
sessions. Query-Dy-Example. QMF component which simplifies the creation of ad-hoc queries. Query Management Facility. End-user interface to 082.
General term for an SQL statement. The action of ignoring those changes made to the database since the last commit . ReSlfuctured Extended Executor. REXX is a high-level programming language functionally similar to CLiST. REXX is more powerful than the CLIST language and has largely superseded it. A horizontal element of a table and is generally synonymous with a record in conventional data processing. Systems Application Architecture. SAA is an IBM concept designed to provide a standard interface to the user (application developer). The dialogue environment for the current user. TSO is the lowest level session. The pool of dialogue variables belonging to the current iSPF
session. Input to a compiler. A source program constitUies the ·computer instruClions· produced by the programmer. Source programs can exist in a number of levels of detail. Low-level languages (e.g. Assembler) require that the programmer has an intimate knowledge of the machine instructions available on the computer on which his program will run . High-level languages (e.g. PUt) remove much of this burden from the programmer and enable him to be more concerned with the procedure required to solve his program; such languages are often referred to as procedure oriented languages. So called 4th generation languages (CLISTS offer certain features) are problem oriented. Modem high-level languages offer structuring facilities. SQL Processor Using File Inpul. A TsoilSPF program which can be used to process SQL statements. It is generally used to test SQL statements, perform simple DB2 administrative
App. CI
SQL
SQLCA
SQLDA
static SQL
system table
table
table space
transaction TSO
unit of recovery unit of work userid
view word
GLOSSARY 201
test SQL statements, perform simple DB2 administrative functions and to load limited amounts of data into DB2 tables . SPUFJ, as its name implies, takes its input from datasets. Structured Query Language . The statements used to access a DB2 database. SQL Communication Area. A system area used by SQL to pass information concerning the execution of an SQL statement back to the program. Its most important field is SOLCOOE,
which indicates the status of the most recently executed SQL
statement. SQL Descriptor Area. A program area used by SQt to obtain (or return) information pertaining to the COiUIlUlS of the specified SQL statement, e.g. COIUIlUl type, coluIlUllength. The creation of SQL statements at the time of writing the program. A database table used for internal administrative purposes, e.g. the system table SYSIBM.SYSTABlES contains an entry for each table (and view) stored in the database. Each system table name is qualified by SYSIBM.
In the database sense, a two-dimensional array of elements stored in or retrieved from the database. The physical (disk) Storage area used to contain one or more tables . Generally synonymous with a query . Time Sharing Option, programming system to provide users with on-line access to computing system. TSO is now a standard MVS component. The interval between two commits or revokes. Transaction. The unique code for the user when he logs onto the TSO
system. Also used by SQL for authorisation purposes . In the database sense, a subset of one or more database tables. A signed binary number which occupies 4 bytes . This is the same imemal representation as a DB2 IHTECiER variable.
Index
abend, 196 access to DB2 tables, 3 ACQUIRE, 162 ADMGDF,18 ADMGDF,38 ADMGGMAP, 18 alpbabetic. 1% alphanumeric, 196 application considerations, 7 application design, 6 application package, build, 83 application plan.
build,86 free, 91 rebind,91
Assemble r, 196 host ya riables. 122
authorisation considerations, 10
balch TSO, 7 BEGIN DECLARE. 138 bind, 79, 196 bind application package, 83 bind application plan, 86 BIND PACKAGE, 83 bind phase, 71 BIND PLAN, 86 binder, 11
Cf370, 197 host variables, 124
CAF interface, I, 104 CAF interface program, 109 Call Attachment Facilily, 104 Callable Interface, 14
invocation syntax, 20 catalog, 197 CICS, 197 CLlST, 197 close cursor, 139 CWSE, lOS, 139 COBOL,197
host variables, 120
column, 191 Command Interface, 14 command procedure, 197 commit, 160, 197 COMMIT. 139 commit point. 160 compile, 79 compile phase, 7 1 compiler. 197 com;ul'Tency.l60 CONNECT, 106 consistency, 160 create lable. example. 172 Cross System Product, 3 esp, 3 cursor, 117, 127, 197
nata Base Request Module, 71 Data Control Language, 3 Data Definition Language, 3 Data Manipulation Language, 3 data modelling, 6 database, 197 database, changes 10, 10 DATABASE2,197 databases, 2 datasel, 197 DB2,197 DB2 bind function, 100 DB2 data Objects, 2 DB2 Interactive. SO, 94 DB2 operalill$ e nvironment, I, 2 DB2 precompIle, 99 DB2 precompiler, 76, 119 DB2 program invocation, 81 DB2 program preparation, 97 DB2 pro~ram, invoke, 93 DB2 seSSIon,
invoke, 82 !enninate, 90
DB2 subeommancls, 83 DB21, 80, 94
global default parameters, set, 103
204 INDEX
DOCS, 197 DBMS, 197 DBRM, 71, 197 DeL,3 DCLGEN, 88,197
in~oke, 97 DD, 197 DDL,3 deadlock, 162 DECLARE CURSOR, 140 DECLARE STATEMENT, 141 DECLARE TABLE, 141 DELETE,142 DESCRffiE, 143 Dialo8 Manager, 14, 197 dialogue, 198 DISCONNECT, 107 DISPLAY· display objet!, 34 DML.3 DSN.82 DSNAU, 79, 104 DSNCU,79 DSNDRm.l94 DSNEU,79 DSNH,82 OSNHASM,75 DSNHASMH,75 DSNHC.75 DSNHCOB.75 DSNHCOB2, 75 DSNHPU.75 DSNTlAR. 118 DSORG.198 DSQ·CANCEL·IND.19 DSg.COMM.LEVEL,19 DS ·INSTANCE·lD.19 D'~'MESSAGE'lD. 19 DS ·MESSAGE-TEXT. 20 DS ·PRODUCT. 19 DS ·PRODUCT·RELEASE, 19 DSg.Q.MESSAGE. ID.1 9 DS ·Q·MESSAGE·TEXT,20 DSQ·RETURN ·CODE. 19 D,~.START'PARM'ERROR' 19 OS ALANG.2 1 DS AROWS.31 DSQCCI.30 DSQCIMSG,31 DSQCIQ09.31 DSQCIQMG.31 DSQCOMM Communi,ations A~a. 18 DSQDEBUG,18 DSQEOIT,18 DSQPRINT. 18 DSgSBSTG, 21 DS SCMO,2 1 DSQSDBCS. 21 DS~SDBUG. 21 DS SIROW,21 DS SMODE.21 DSgSPILL, 18.21 DS SPUN,21 D'gSPRID,21 DS SRSTG.22 DSQSRUN,22 D'~SSUBS, 22 DS UCFRM.18 DS UDUMP.18 dynamic SQL, 117. 130. 198
with a variable number of ,olumns, 1)2
DYNAMNBR,8
embedded SQL. 116. 198 statements, 137
END. 90 END· end ,urnnt operation. 35 END DECLARE, 144 ERASE • remo~e object from database. 35 ESQL. 198 e~'lusive lod, 162 exe" 198 EXECUTE, 144 EXECUTE IMMEDIATE, 145 EXIT· terminate QMF session. 36 EXPLAIN,146 EXPORT. 57 EXPORT· transfer obje't to external dataset.
36
FETCH, ISO file. 198 font. 186 FORTRAN. 198 FREE. 91 f~e apph,ation plan. 9]
GDDM.198 GDF. ]98 GRANT. !o graphic data, ]98
half·word. 198 HELp· display help infotmition. 38 help environment. 198 help panel. 198 host language, 198 host system ,ornp<ment, in~oke, 15 host ~ariable, 116, 198
ICU. \4. 198 IKJEFfOI, TSO tenninal monitor program.
7.80 implic:it ,ummit, 160 implicit locks. 162 implicit rollback. 160 IMPORT. 57 IMPORT · impoft object into the QMF
en~ironmcnt, 38 IMS.198 INCLUDE. 151 index. 2 indic:ator variable. 116. 125. 198 INSERT,151 inseft records into table , example, 172 Integration Exchange Fnnnat, 37 INTERACT . plo~lde interactive suppoft, 39 Interactive Chaft Utility, 14 interactive SQL, L 99 Interacti~e Slstem Productivity Facility , 3 isolation, 16 ISPEXEC, 199 [SPF, 14, 199 ISPF - invoke ISPFIPDF panel. 40 ISPUNK, 199 ISPSTART, 16, 199 IXF,37
column record, 60 data, 58 data record, 60 header record, 58
table record, 59
JeL, 199 procedure step names, 74 procedures, 73, 74
library, 199 linkage editor phase. 71 linkage editor, 79, 199 LIST - display list of QMF obj«:ts. 40 load module, 199 LOCK TABLE, 152 locking, 199 logicaf unit of work. 159 lost update, 161 LRECL,I99
member, 199 MESSAGE - display message, 41
null, l99
objeci module, 199 OPEN. 108. 153
package, 71. 199 panel. 199 partitioned dataset, 199 PDF,I99 pcrfonnance, 6 PGF,I99 PUI,200
host variables, 119 preprocessor. 75
plan. 71. 200 PLAN TABLE, principal anrihulcs, 147 pre-liniedit, 79 precompilation. 200 precompile phase, 71 preparation Slep parameters, 14 PREPARE, IS4 prepare program in foreground, 82 PRINT - pnnl contents of objet!. 42 profile pool, 200 program hOSI variables, 119 program invoke independent of DB2, 104 program preparation, 71 program solution, example, 179 promote locks, 162
QBE, 13,200 QMF - execute explicit QMF command, 45 QMF, 3, 12,200
Assembler inlerface, 22 C Interface, 26 Callable Interface, IS Chart, 14 CICS subset, 14 COBOL inlerface, 24 Command Facilities, 15 command, r,assins paramelel'5 to, 31 Command nterface, 30 commands, 33 data, 13 data format, 64 data header record, 64 data value record, 65 direct invocation of, 16 external data format, 57 files, 17
fonn, 13 invocation, 14
sample CLlST, IS objects, 12
administration of. 15 transfer, 15
parameter list format, 20 PUI interface, 27 procedure, 14 profile, 14 program, DSQQMFE, 16 query, 13 report, 13
end record, 69 format, 13,66
INDEX 205
header record format, 66 line record, 68 line continuation record, 69 table record format, 67 table row record, 67
REXX interface, 29 solution, example, 175 starus, 30
variables, 3 I wort area, 13
query, 200 Query by Example, 13 Query Managemellt Facility , 3,12
REBIND,91 rebind application plall 91 Release Information Block, 107 RELEASE, 162 RESET - clear object, 45 RESET GLOBAL - clear query object, 46 RESET QUERY - clear query object, 46 REVOKE", 10 REXX, 200 RIB, 194 ROLLBACK, 155 rollback. 160 row, 200 RUN,93 RUN - execute object, 46 run an SQL program. 101
S-lock, 162 SAA,200 SAVE - save contents of wort area, 47 SAVE DATA - save contents of data area, 48 SAVE PROFILE - save profIle, 49 SELECT,16 SELECT INTO, 155 session. 200 SET ~ROFILE) - set profile, 49 SET LOBAL - set global variable. 51 shared lock. 162 shared pool, 200 source program, 200 SPUFI, 3, 94, 200 SPUFI. invoke, 95 SQL,201
operating environment, 3 program, run, 101 rerum code, 118 starus, 117 transaction concepts, 159 use of, 3 used from PfOlrams, 125 used from app ications, 4
206 INDEX
S8l Communi~ation Area, 117 S l Processor Using File Input, 3, 94 S8lCA, \ 17, 187,101 S lCABC, 188 SQLCAID, 188 SQlCODE, 11 7, 118, 127, 188 S8lD, 132, 191 S LDA, 190, 20 1
no standard COBOL definition, 132 SQLDABC, 191 S8LDAID, 191 S LDATA, 132, 191 S8lERRD, 188 S LERRM, 188 SQLERRP, 188 SQLlND, 132, 191 SQLLEN , 191 SQLN, 132, 191 SQLNAME, 191 SQLTYPE,I91 SQLVAR, 132, 191 SQLWARN, 188 SQLWARNO, 118 SlART ~ommand , 21 stan declarations, 138 STATE - rerum QMF starus, 51 stati~ SOl, 117, 125,201
SEL£CT with a fixed number of columns and multiple rows, 127
syntax diagram, 184 system table, 201 SYSTSIN,8 SYSTSPRT,8
table, 2, 20 1 table de~laration generator, 88 table space, 2, 201 temporary storage area, 13 timeout, 162 transa~tion, 159,201 transaction processing, 159 TRANSLATE, 109 TSO, 201
batc ll ,7 TSO - invoke TSO command, 51
U-Iock, 162 uncommined depeooency, 161 unit of recovery, 160,201 unit of work, 201 unrepeatable reads, 161 update, 162 UPDATE, I56 uscrid,201
view, 2, 201
WHENEVER, 157 word,201 worked example, 171
X-lock, 162