Вы находитесь на странице: 1из 40

OS400 Concepts

OS400 Concepts

Sales Transaction Processing on AS400

Hard Disk

S/W Appl.

COBOL

/RPG

CICS

Business

Data

DB2 400

Files

OS/400

CL
CL

RAM/Buffer

Hard Disk S/W Appl. COBOL /RPG CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer
AS400 Hard Disk S/W Appl. COBOL /RPG CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer

Sales Transaction Processing on AS400

Hard Disk

S/W Appl.

COBOL

/RPG

CICS

Business

Data

DB2 400

Files

OS/400

CL
CL

RAM/Buffer

Hard Disk S/W Appl. COBOL /RPG CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer
Store1 Store2
Store1
Store2
Store3 Store4
Store3
Store4
Store5 Store6
Store5
Store6
CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer Store1 Store2 Store3 Store4 Store5 Store6

Sales Transaction Processing on AS400

Hard Disk

S/W Appl.

COBOL

/RPG

CICS

Business

Data

DB2 400

Files

OS/400

CL
CL

RAM/Buffer

Hard Disk S/W Appl. COBOL /RPG CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer
Store1 Store2
Store1
Store2
Store3
Store3
Store4 Store5
Store4
Store5

Store6

CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer Store1 Store2 Store3 Store4 Store5 Store6

How to connect a PC to the AS400

How to connect a PC to the AS400

How to connect a PC to the AS400

Follow these steps to connect a PC to the AS400 :

How to connect a PC to the AS400 Follow these steps to connect a PC to

How to connect a PC to the AS400

Follow these steps to connect a PC to the AS400 :

1. Install an Emulation S/W (Emulator) on the PC. Eg : Mocha, Attachmate, Telnet, etc.

2. Specify the IP Address of the AS400 on the Emulator.

3. Thru Internet Connectivity, we can connect a PC to the AS400.

2. Specify the IP Address of the AS400 on the Emulator. 3. Thru Internet Connectivity, we

Sales Transaction Processing on AS400

Hard Disk

S/W Appl.

COBOL

/RPG

CICS

Business

Data

DB2 400

Files

OS/400

CL
CL

RAM/Buffer

Hard Disk S/W Appl. COBOL /RPG CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer
Store1 Store2
Store1
Store2
Store3
Store3
Store4 Store5
Store4
Store5

Store6

CICS Business Data DB2 400 Files OS/400 CL RAM/Buffer Store1 Store2 Store3 Store4 Store5 Store6

OS400 Objects

On the AS/400, everything that can be stored or retrieved is stored in an object. Eg : Libraries, files, executable programs, queues, and more.

Objects share some common attributes such as name, type, size, description, date created, and owner.

The concept of an object allows the system to perform certain standard operations, such as authorization management, on all objects types. The object types that we will be primarily concerned are:

*LIB Libraries

*FILE Files

*PGM Compiled programs *OUTQ Output queues

types that we will be primarily concerned are: *LIB Libraries *FILE Files *PGM Compiled programs *OUTQ

OS400 Objects

QSYS library (*LIB)

OS400 Objects QSYS library (*LIB) Special system Library User Defined Libraries (*LIB) Programs(*PGM) (Executable)

Special system Library

User Defined Libraries (*LIB)

(*LIB) Special system Library User Defined Libraries (*LIB) Programs(*PGM) (Executable) Outqueues (*OUTQ) Contains
(*LIB) Special system Library User Defined Libraries (*LIB) Programs(*PGM) (Executable) Outqueues (*OUTQ) Contains

Programs(*PGM)

(Executable)

Outqueues

(*OUTQ)

(*LIB) Programs(*PGM) (Executable) Outqueues (*OUTQ) Contains Spooled files for printer Files (*FILE) Other

Contains Spooled files for printer

Files (*FILE)

(*OUTQ) Contains Spooled files for printer Files (*FILE) Other Objects Physical Files Logical Files Data Physical

Other Objects

Physical Files

files for printer Files (*FILE) Other Objects Physical Files Logical Files Data Physical Files Source Physical
files for printer Files (*FILE) Other Objects Physical Files Logical Files Data Physical Files Source Physical

Logical Files

Data Physical Files

Source Physical Files

Physical Files Logical Files Data Physical Files Source Physical Files Contains Actual Data Contains Source Programs

Contains

Actual Data

Contains

Source Programs

Physical Files Logical Files Data Physical Files Source Physical Files Contains Actual Data Contains Source Programs

OS400 Objects

Libraries

Every object is contained in a library. A library is an object, of type *LIB, that contains a group of objects. We can term it as a “root”.

A library cannot "contain" other libraries (with the exception of QSYS, the system master library, which "contains" all libraries on the system).

Note : Two users cannot have libraries with the same name. There are basically three general categories of libraries:

1. QSYS - the library that contains all other libraries,

2. System supplied libraries (NOTE:all IBM-supplied library names begin

with the letter "Q" or "#" )

3. User-created libraries.

( NOTE:all IBM-supplied library names begin with the letter "Q" or "#" ) 3. User-created libraries.

OS400 Objects

Files

A file is an object, of type *FILE, that contains data in the form of a database, device data, or a group of related records that are handled as a unit.

There are two types of database files:

1. Physical files

2. Logical files.

A physical file contains actual data stored on the system. It has a

fixed-length record format. There are two kinds of physical files:

1. Data physical files

2. Source physical files.

has a fixed-length record format. There are two kinds of physical files: 1. Data physical files

OS400 Objects

QSYS library (*LIB)

OS400 Objects QSYS library (*LIB) Special system Library User Defined Libraries (*LIB) Programs(*PGM) (Executable)

Special system Library

User Defined Libraries (*LIB)

(*LIB) Special system Library User Defined Libraries (*LIB) Programs(*PGM) (Executable) Outqueues (*OUTQ) Contains
(*LIB) Special system Library User Defined Libraries (*LIB) Programs(*PGM) (Executable) Outqueues (*OUTQ) Contains

Programs(*PGM)

(Executable)

Outqueues

(*OUTQ)

(*LIB) Programs(*PGM) (Executable) Outqueues (*OUTQ) Contains Spooled files for printer Files (*FILE) Other

Contains Spooled files for printer

Files (*FILE)

(*OUTQ) Contains Spooled files for printer Files (*FILE) Other Objects Physical Files Logical Files Data Physical

Other Objects

Physical Files

files for printer Files (*FILE) Other Objects Physical Files Logical Files Data Physical Files Source Physical
files for printer Files (*FILE) Other Objects Physical Files Logical Files Data Physical Files Source Physical

Logical Files

Data Physical Files

Source Physical Files

Physical Files Logical Files Data Physical Files Source Physical Files Contains Actual Data Contains Source Programs

Contains

Actual Data

Contains

Source Programs

Physical Files Logical Files Data Physical Files Source Physical Files Contains Actual Data Contains Source Programs

OS400 Objects

Data Physical File

1. It contains physical data such as

an input file to a program like

Employee Master file.

Source Physical File

1. It contains source statements

such as statements of COBOL

PASCAL, etc.

2. It cannot be compiled.

3. It has a record format defined

using DDS(Data Description Specifications a language that is used to describe database files to system).

4. It has an attribute PF-DTA.

2. It must be compiled.

3. It is created using CRTSRCPF

command/F6 with a default record length 92(80 for the source data field, 6 for the sequence number field, and 6 for the date field).

4. It has an attribute PF-SRC.

for the source data field, 6 for the sequence number field, and 6 for the date

OS400 Objects

Note : The data physical file and source physical file can have members. But these members are not objects themselves but only the subsets of an object.

Use of specifying attribute :

Specifying attribute will allow the system programs like editors/compilers to recognize the type of source file.

For example, a member has been specified as having an attribute of CBL (for

COBOL program,) the AS/400 editor, SEU, will format the program as a COBOL

program, and when PDM (Program Development Manager) is given the instruction

to compile the file, it "knows" that it should invoke the COBOL compiler.

CBL indicates it is a COBOL program

RPG indicates it is a RPG program

CLP indicates it is a Control Language program DSPF indicates it is a DISPLAY file(online screen) PGM indicates it is a compiled code

PF indicates it is a Physical file

LF indicates it is a Logical file

screen) PGM indicates it is a compiled code PF indicates it is a Physical file LF

OS400 Objects

Physical File

Logical File

1.

It contains both structure and physical data such as an input

1.

It is just a structure and a view of physical file data.

file or a program.

2.

It can be compiled but each time file is compiled, data is

2.

It can be compiled any number of times and no data loss as is

deleted.

does not contain any data.

3.

It has a record format defined using DDS(Data Description Specifications a language that

3.

3. It has a record format defined using DDS(Data Description Specifications a

is used to describe database

language that is used to

files to system) or using CL command CRTPF/CRTSRCPF.

describe database files to system) or using CL command CRTLF.

4.

It has an attribute PF-DTA.

4.

It has an attribute LF.

files to system) or using CL command CRTLF. 4. It has an attribute PF-DTA. 4. It

Program Development Manager(PDM)

The Program Development Manager (PDM) is a set of utilities under OS/400 designed to simplify the creation and development of software. It automates file and member creation, editing, compilation and program execution, and allows the programmer to manage their environment from a set of standard menus.

PDM can be used in 2 ways.

1. Use the command STRPDM (for Start PDM,) which will produce a menu of

options for the level on which the user wishes to work (libraries, objects, or members,) .

2. Use one of three commands which indicate the level at which the user would like

to work:

WRKLIBPDM

WRKOBJPDM

WRKMBRPDM

-- Work with libraries using PDM -- Work with objects using PDM

-- Work with file members using PDM

WRKOBJPDM WRKMBRPDM -- Work with libraries using PDM -- Work with objects using PDM -- Work

Source Entry Utility(SEU)

Source Entry Utility (SEU) is used to work with source members in source physical files, and the records contained in source members.

With SEU, you can do operations such as:

Create members

Edit members (code programs)

Print members

Copy records into a member from another member or spooled file

• Edit members (code programs) • Print members • Copy records into a member from another

Screen Design Aid(SDA)

Screen Design Aid (SDA) is used to perform the following tasks:

1. Design a menu to present a list of options from which the user makes a Selection

2. Design a display to help the user navigate through an application program

3. Create online help information for displays and menus.

display to help the user navigate through an application program 3. Create online help information for

Data Description Specifications(DDS)

Data Description Specifications (DDS) describe data attributes in file descriptions that are external to the application program that processes the data.

File Types that use DDS :

1. Physical and logical files

2. Display files

3. Printer files

4. ICF files (Intersystem communications function files)

: 1. Physical and logical files 2. Display files 3. Printer files 4. ICF files (Intersystem

End of Day 2 session

End of Day 2 session