Upload
sambitmech
View
376
Download
7
Tags:
Embed Size (px)
Citation preview
LEMURIA TECHNOLOGIES LTD 1
CA – IDMS / ADS
Overview
LEMURIA TECHNOLOGIES LTD 2
Dialog StructureAn ADS program is called a DIALOG.
A single dialog consists of the following:
1) one optional subschema
2) one optional map
3) one optional premap (process module)
4) one or more optional work records
5) one or more optional response processes (modules associated
with a PFkey or command)
LEMURIA TECHNOLOGIES LTD 3
Dialog Flow
1. Premap code (if any) begins executing. Database run-unit is started if there is any database I/O in the premap. The database run-unit is finished. The premap ends by displaying the MAP.
2. Program frees as many resources as possible, and waits for user to press the ENTER or a function key.
3. Program wakes up and does a map in.
4. Based on the function key pressed, the code in the appropriate response module is executed. A database run-unit is started at the time of the first database I/O.
5. The response code ends when a DISPLAY statement is executed (causes a MAP OUT) or when a statement such as RETURN or LEAVE ADS or a LINK to another DIALOG is encountered.
LEMURIA TECHNOLOGIES LTD 4
IDMS Mapping
Mapping Overview
The world of online mainframe systems has long been built around the IBM
3270 terminal. Mapping basically involves sending or receiving a data
stream to or from a 3270 terminal, and IDMS’s mapping was probably
modeled after IBM’s CICS BMS (Basic Mapping Support).
There are two ways of working with a terminal:
1) line mode - reading and writing one line at a time
2) mapping mode - the concept of sending and receiving an
entire screen at a time
Personal Computers continue the 3270 tradition by providing "terminal
emulators", which are software packages that allow a window on your PC to
look like a 3270 mainframe session.
LEMURIA TECHNOLOGIES LTD 5
Contd..
• Mapping became popular because it maximizes CPU time and transmission time.
• The user looks at the screen, fills in some fields, and then presses"ENTER" or a PFkey.
• The entire screen (map) is sent to the mainframe, a program is invoked to process the map, database I/O is done, the map is
reformatted (or a new map is built), then the data is returned to the terminal.
• Most mainframe sites use VTAM - Virtual Terminal Access Method as a layer between the terminal and the software.
LEMURIA TECHNOLOGIES LTD 6
Contd..
There is usually one additional layer between VTAM and the programmer
- and that is called a TP-monitor - where TP stands for Tele Processing.
IBM has long provided a TP monitor called CICS (Customer Information
Control? System) and its mapping language is called BMS (Basic
Mapping Support).
IDMS came out with a TP-monitor called DC (Data Communications). So
all IDMS online products use "DC" commands to communicate with maps
built by the Mapping Compiler. Some companies wanted to run IDMS
under CICS or TSO or other TP monitors, therefore IDMS provided UCF
(Universal Communications
LEMURIA TECHNOLOGIES LTD 7
Contd..
LEMURIA TECHNOLOGIES LTD 8
Contd..
LEMURIA TECHNOLOGIES LTD 9
Error Message FieldDisplaying error messages: A maximum of one message field can bedefined on any given map; a message field can be of any length. Whenseveral data fields submit incorrect input, the message field displays asmany error messages as possible, in order of occurrence (from top tobottom and left to right) of the incorrect data fields.
Messages in the detail area: A message field that is defined in the detail area of a page able map is mapped out once in each occurrence ofthe detail occurrence in the detail area. Messages generated by the CA-DS DISPLAY MESSAGE statement are not displayed if the message field isdefined in the detail occurrence for the map.
Message sources: A message field displays messages generated fromeither of the following sources:
-The error-handling capability of the CA-IDMS mapping facility
- The CA-ADS dialog or application program that uses the map
LEMURIA TECHNOLOGIES LTD 10
Starting Task MAPC
Starting the Online Mapping Compiler
From the CA-IDMS DBDC "Enter NextTask Code Prompt:" type in MAPC (orany other name that your site may havedefined as the task code).
LEMURIA TECHNOLOGIES LTD 11
Contd..
When a new session is initiated, as when the online compiler isinvoked from CAIDMS, a new queue record is built. When asuspended session is invoked, the queue record from the suspendedsession is used.
LEMURIA TECHNOLOGIES LTD 12
Building a Map
LEMURIA TECHNOLOGIES LTD 13
Contd..
This course assumes that you already know about IDMS dictionaries. Allpieces of an ADS application are typically stored in the same dictionary.Often, your site administrators will automatically logon you on to the properdictionary. It is also possible that you might switch between multipledictionaries depending on the project you are working on.
You can type in the dictionary name on the screen above, or on the TCF(Transfer Control Facility) screen, or by using the DCUF command fromthe command prompt.
Adding, Copying, or Deleting a MapMAPC and ADSC follow the CUA (Common User Access), also called"ACTION BAR" or pull down menu.
To add a new map:
1) type in the map name (and optionally the dictionary name, otherwise the dictname will default).
NOTE: Check with your site standards for map naming conventions.
2) Move the cursor over the word "add" (upper left corner of the screen) and press enter.
LEMURIA TECHNOLOGIES LTD 14
Contd..
LEMURIA TECHNOLOGIES LTD 15
Contd..
3) You can copy the map from another map by entering the source map name
or you can just press enter to create a new empty map.
Copy Option 1 "All" specifies to copy the entire map along with all records and
elements.
Copy Option 2 "Format" specifies to copy the format of the map, but not to copy
the element definitions.
For now, we don’t have any existing maps to copy from. This feature will be
demonstrated later.
LEMURIA TECHNOLOGIES LTD 16
Contd..
LEMURIA TECHNOLOGIES LTD 17
Contd..
On the pull down menu that appears, type in 2 in order to delete the map.
You must confirm that you really want to delete the map before continuing.
This is shown on the next page.
LEMURIA TECHNOLOGIES LTD 18
Contd..
LEMURIA TECHNOLOGIES LTD 19
Contd..
LEMURIA TECHNOLOGIES LTD 20
Contd..
LEMURIA TECHNOLOGIES LTD 21
Contd..
The "MODIFY" option on the action bar relates to map checkout.
"CHECKOUT" allows a developer to have sole access to a map.
The map is protect from additional updates until has been
checked in (released).
"RELEASE" - releases the developers hold on a map so that
other developers may modify it.
"LIST" - display a list of all maps checked out to the user signed
on.
LEMURIA TECHNOLOGIES LTD 22
Contd..
LEMURIA TECHNOLOGIES LTD 23
Other MAPC Menu Options
Other options exist on the ACTION BAR, but they will be covered later in thetutorial.
This section is designed primarily for beginners - so right now - you need tolearn the basics of building a simple map - and not get hung up on all theadvanced features.
Right now - a beginner needs to learn the following:
1) How to attach map work records to the map2) How to define the literals and fields to the map3) How to compile the map
Each of these topics will be covered in following sections.
LEMURIA TECHNOLOGIES LTD 24
Associated Records
Before building a map, usually the developer (or some other appointedperson) has built the necessary map work records on the IDD (IntegratedData Dictionary).
Building elements and records on the dictionary is covered in another partof this course.
Map Work Records are similar to a working-storage section of a COBOLprogram. A record is like an 01 level - with several fields or elements underit. The 01 level (or record-name) must be attached to your map before youadd any elements from that record to your map.
LEMURIA TECHNOLOGIES LTD 25
Contd..
NOTE: Most sites require that element names be unique. This isusually done by using a record prefix or suffix. For example, theelement name might be EMPNUM on the dictionary, but in one recordit might be EMP-NUM-M101 (where the suffix is '-M101') or MAP1-EMP-NUM (where the prefix is 'MAP1-'). Often times, a special maprecord will be built for each map, and the record name will containthe map-name, or the numerical part of the map name.
Example:
MAP-NAME= EMP0100M RECORD-NAME=EMP0100M-MAP-RECORD
or RECORD-NAME=EMP-MAP-RECORD-0100
Some sites have very strict naming conventions, other sites mayhave no naming conventions.
LEMURIA TECHNOLOGIES LTD 26
Mapping to Database Records?IDMS allows you to map directly to database records. While this makesthe programming somewhat easier by eliminating move statementsbetween the database fields and the map fields, there are complications.
If the database needs to be restructured, and the database record isassociated with several maps, the DBA has two options:
1) create a new version of the database record2) decompile all maps, change the record, then restore all maps
Check with your site's procedures as to whether you should map todatabase records. Some sites have standards that you should or shouldnot do so. The examples in this course will use intermediate MAP workrecords.
LEMURIA TECHNOLOGIES LTD 27
Contd..
LEMURIA TECHNOLOGIES LTD 28
LEMURIA TECHNOLOGIES LTD 29
Contd..
LEMURIA TECHNOLOGIES LTD 30
Contd..
LEMURIA TECHNOLOGIES LTD 31
Contd..
LEMURIA TECHNOLOGIES LTD 32
Contd..
LEMURIA TECHNOLOGIES LTD 33
Contd..
LEMURIA TECHNOLOGIES LTD 34
Contd..
LEMURIA TECHNOLOGIES LTD 35
Contd..
LEMURIA TECHNOLOGIES LTD 36
Contd..
Each site will have defined a special character to use to identify new and
changed fields.
The % sign is often used for this character.
Place one % sign in front of each literal, then just type in the literal.
Then press PF5 to proceed. PF5 is the "NEXT KEY" - and will usually take
you where you need to go next.
LEMURIA TECHNOLOGIES LTD 37
Contd..
LEMURIA TECHNOLOGIES LTD 38
Contd..
You will see one "Literal Definition" screen for each literal that you defined.
A small part of your layout screen is shown, with the current literal
highlighted.
Each site will have its own screen design procedures. Usually the map name
goes somewhere on the top, often with the date/time. There are usually
standards as to how literals and variables should be displayed.
We will accept the defaults for now.
Display Intensity
1. Normal 2. Bright or 3. Hidden
LEMURIA TECHNOLOGIES LTD 39
Contd..
Hidden fields are available for such things as a password entry field.
Bright fields are usually shown brighter - or in a different color - depending on
your terminal emulation software. Many people now use Personal Computers
to emulate a 3270 session, and the PC has the power to re-interpret these
characteristics according to the PC users options.
Highlighting –
1. Blink 2. Reverse Video or 3. Underline
NOTE: not all 3270 terminals support these functions
LEMURIA TECHNOLOGIES LTD 40
Contd..
At end of field (for variable fields, not literals) - what happens if the user types
one character more than size of field?
1. Auto-tab - automatically tab to the next field, and insert that character as the
first character in the next field.
2. Lock keyboard - puts the "stick-man" or "X" at the bottom of the terminal,
prevents any further typing until the user presses the "RESET" key and manually puts the cursor in a valid position.
3. Take no action - just lets the user keep on typing.
Color - obviously sets the color of the field - but remember that a PC user may
have his colors re-mapped to some other set of colors.
LEMURIA TECHNOLOGIES LTD 41
Contd..
LEMURIA TECHNOLOGIES LTD 42
Contd..
Notice how the literal fields all have the other field symbol preceding them.
Now prepare the screen for each variable field. Put a % mark at each
location where you wish to define a variable field.
Then press PF5 for NEXT.
LEMURIA TECHNOLOGIES LTD 43
Contd..
LEMURIA TECHNOLOGIES LTD 44
Contd..
LEMURIA TECHNOLOGIES LTD 45
Contd..
Be sure to include any prefix or suffix. We are using the map name as a
record element prefix (EMP0100M-).
After typing in the field name, press ENTER - and the results are shown
on the next screen.
LEMURIA TECHNOLOGIES LTD 46
Contd..
LEMURIA TECHNOLOGIES LTD 47
Contd..
The mapping compiler automatically fills in the picture and the other fields
from information on the IDD.
You may now change the fields as desired (shown on next page).
LEMURIA TECHNOLOGIES LTD 48
Contd..
LEMURIA TECHNOLOGIES LTD 49
Contd..
The Edit Picture will allow employee-id to be displayed without leading
zeroes.
It is a common procedure to make input fields bright and all other fields
normal intensity, so "2" was entering for intensity.
We will use auto-tab as a standard for all input fields.
Since the user must type in the employee-id to do a query the field must be
unprotected.
Press PF5 to continue to the next variable field.
LEMURIA TECHNOLOGIES LTD 50
Contd..
LEMURIA TECHNOLOGIES LTD 51
Contd..
If you are processing more than one variable field at a time, then the next
variable field is highlighted.
Note that that the length of the field is only one character until you type in
the element name (then the length is determined by the Edit Picture).
LEMURIA TECHNOLOGIES LTD 52
Contd..
LEMURIA TECHNOLOGIES LTD 53
Contd..
LEMURIA TECHNOLOGIES LTD 54
Contd..
On the prior screen, an invalid element name was entered.
Note the error message (in red) on this screen).
What did we do wrong?
The M was omitted from the element prefix.
It should have been EMP0100M-LAST-NAME, so we correct the element
name and try again.
LEMURIA TECHNOLOGIES LTD 55
Contd..
LEMURIA TECHNOLOGIES LTD 56
Contd..
LEMURIA TECHNOLOGIES LTD 57
Adding a Message Field
LEMURIA TECHNOLOGIES LTD 58
Contd..
LEMURIA TECHNOLOGIES LTD 59
Contd..
LEMURIA TECHNOLOGIES LTD 60
Contd..
LEMURIA TECHNOLOGIES LTD 61
Contd..
LEMURIA TECHNOLOGIES LTD 62
Contd..
LEMURIA TECHNOLOGIES LTD 63
Contd..
LEMURIA TECHNOLOGIES LTD 64
Contd..
LEMURIA TECHNOLOGIES LTD 65
Contd..
LEMURIA TECHNOLOGIES LTD 66
Contd..
LEMURIA TECHNOLOGIES LTD 67
Contd..
LEMURIA TECHNOLOGIES LTD 68
Contd..
LEMURIA TECHNOLOGIES LTD 69
Contd..
LEMURIA TECHNOLOGIES LTD 70
Contd..
LEMURIA TECHNOLOGIES LTD 71
Contd..
LEMURIA TECHNOLOGIES LTD 72
Contd..
LEMURIA TECHNOLOGIES LTD 73
Batch Mapping
LEMURIA TECHNOLOGIES LTD 74
Contd..
LEMURIA TECHNOLOGIES LTD 75
Contd..
LEMURIA TECHNOLOGIES LTD 76
LEMURIA TECHNOLOGIES LTD 77
Contd..
LEMURIA TECHNOLOGIES LTD 78
LEMURIA TECHNOLOGIES LTD 79
Contd..
LEMURIA TECHNOLOGIES LTD 80
Contd..
LEMURIA TECHNOLOGIES LTD 81
Contd..
LEMURIA TECHNOLOGIES LTD 82
Contd..
LEMURIA TECHNOLOGIES LTD 83
Start Task ADSC
LEMURIA TECHNOLOGIES LTD 84
Contd..
LEMURIA TECHNOLOGIES LTD 85
TCF – Transfer Control Facility
LEMURIA TECHNOLOGIES LTD 86
Contd..
LEMURIA TECHNOLOGIES LTD 87
Initial Screen
LEMURIA TECHNOLOGIES LTD 88
Contd..
LEMURIA TECHNOLOGIES LTD 89
Contd..
LEMURIA TECHNOLOGIES LTD 90
Contd..
LEMURIA TECHNOLOGIES LTD 91
Contd..
LEMURIA TECHNOLOGIES LTD 92
Dialog Options and Directives Screen
LEMURIA TECHNOLOGIES LTD 93
LEMURIA TECHNOLOGIES LTD 94
Contd..
LEMURIA TECHNOLOGIES LTD 95
Contd..
LEMURIA TECHNOLOGIES LTD 96
Contd..
LEMURIA TECHNOLOGIES LTD 97
Subschema/Database Specifications
LEMURIA TECHNOLOGIES LTD 98
Contd..
LEMURIA TECHNOLOGIES LTD 99
Contd..
LEMURIA TECHNOLOGIES LTD 100
Work-Records
LEMURIA TECHNOLOGIES LTD 101
Contd..
LEMURIA TECHNOLOGIES LTD 102
Process Modules
LEMURIA TECHNOLOGIES LTD 103
Contd..
LEMURIA TECHNOLOGIES LTD 104
contd..
LEMURIA TECHNOLOGIES LTD 105
Contd..
LEMURIA TECHNOLOGIES LTD 106
LEMURIA TECHNOLOGIES LTD 107
Contd..
LEMURIA TECHNOLOGIES LTD 108
Contd..
LEMURIA TECHNOLOGIES LTD 109
Contd..
LEMURIA TECHNOLOGIES LTD 110
ADS PROGRAMMING LESSONS
LEMURIA TECHNOLOGIES LTD 111
Contd..
LEMURIA TECHNOLOGIES LTD 112
Contd..
LEMURIA TECHNOLOGIES LTD 113
Contd..
LEMURIA TECHNOLOGIES LTD 114
Contd..
LEMURIA TECHNOLOGIES LTD 115
Contd..
LEMURIA TECHNOLOGIES LTD 116
Contd..
LEMURIA TECHNOLOGIES LTD 117
Contd..
LEMURIA TECHNOLOGIES LTD 118
Contd..
LEMURIA TECHNOLOGIES LTD 119
Contd..
LEMURIA TECHNOLOGIES LTD 120
Contd..
LEMURIA TECHNOLOGIES LTD 121
Contd..
LEMURIA TECHNOLOGIES LTD 122
Contd..
LEMURIA TECHNOLOGIES LTD 123
Contd..
LEMURIA TECHNOLOGIES LTD 124
Contd..
LEMURIA TECHNOLOGIES LTD 125
Contd..
LEMURIA TECHNOLOGIES LTD 126
Contd..
LEMURIA TECHNOLOGIES LTD 127
Contd..
LEMURIA TECHNOLOGIES LTD 128
Contd..
LEMURIA TECHNOLOGIES LTD 129
Contd..
LEMURIA TECHNOLOGIES LTD 130
Contd..
LEMURIA TECHNOLOGIES LTD 131
Contd..
LEMURIA TECHNOLOGIES LTD 132
Contd..
LEMURIA TECHNOLOGIES LTD 133
Contd..
LEMURIA TECHNOLOGIES LTD 134
Contd..
LEMURIA TECHNOLOGIES LTD 135
Contd..
LEMURIA TECHNOLOGIES LTD 136
Program 2 - PFKey Enhancements
LEMURIA TECHNOLOGIES LTD 137
Contd..
LEMURIA TECHNOLOGIES LTD 138
Contd..
LEMURIA TECHNOLOGIES LTD 139
Contd..
LEMURIA TECHNOLOGIES LTD 140
Contd..
LEMURIA TECHNOLOGIES LTD 141
Contd..
LEMURIA TECHNOLOGIES LTD 142
Contd..
LEMURIA TECHNOLOGIES LTD 143
Contd..
LEMURIA TECHNOLOGIES LTD 144
Contd..
LEMURIA TECHNOLOGIES LTD 145
Contd..
LEMURIA TECHNOLOGIES LTD 146
Contd..
LEMURIA TECHNOLOGIES LTD 147
Contd..
LEMURIA TECHNOLOGIES LTD 148
Contd..
LEMURIA TECHNOLOGIES LTD 149
Contd..
LEMURIA TECHNOLOGIES LTD 150
Contd..
LEMURIA TECHNOLOGIES LTD 151
Contd..
LEMURIA TECHNOLOGIES LTD 152
Contd..
LEMURIA TECHNOLOGIES LTD 153
Contd..
LEMURIA TECHNOLOGIES LTD 154
Contd..
LEMURIA TECHNOLOGIES LTD 155
Contd..
LEMURIA TECHNOLOGIES LTD 156
Contd..