You are on page 1of 14

Control Specifications Positions or Keyword Name 6 7-80 ACTGRP Form type Keywords Activation group *NEW | *CALLER | 'activationgroup-name'

{*NONE | *SRC | *EXT} *NO | *INPUTONLY | *USRCTL *LIBRCRTAUT | *ALL | *CHANGE | *USE | *EXCLUDE | 'authorizationlist-name' 'binding-directory -name' {:'bindingdirectory-name'...} *GRAPH: *IGNORE | *SRC | number *UCS2: number 1-2048 'string' 'symbol' *{NO}DATETIME *{NO}GRAPHIC *{NO}VARCHAR *{NO}VARGRAPHIC fmt{separator} fmt{separator} {*NO | *YES} *JOBRUN | 'value' *YES | *NO rpg_name *PEP | *ENTRYEXIT | *FULL *MAXDIGITS | *RESDECPOS {*NO | *YES} *{NO}ZONED *{NO}INPUTPACKED {*NO | *YES} {*NO | *YES} {*NONE | *SRC} 0-20 *NONE | 'character-value' 10 | 20 *JOBRUN | *JOB | 'languageidentifier' Entry H RPG III 6 n/a n/a

ALTSEQ ALWNULL AUT

Alternate collating sequence Allow null-capable fields Authority

26 n/a n/a

BNDDIR

Binding directories

n/a

CCSID CCSID COPYNEST COPYRIGHT CURSYM CVTOPT

Default graphic CCSID Default UCS-2 CCSID Maximum nesting level Copyright string Currency symbol Convert options

n/a n/a n/a n/a 18 n/a

DATEDIT DATFMT DEBUG DECEDIT DFTACTGRP DFTNAME ENBPFRCOL EXPROPTS EXTBININT FIXNBR FLTDIV FORMSALIGN FTRANS GENLVL INDENT INTPREC LANGID

Date edit (Y edit code) Date format Debug Decimal notation Default activation group Default name Enable performance collection Expression options Integer format for externallydescribed binary fields Fix decimal data Floating point division Forms alignment File Translation Generation level Indent in source listing Integer precision Language identifier

19,20,21 n/a 15 21 n/a 75-80 n/a n/a n/a n/a n/a 41 43 n/a n/a n/a n/a

NOMAIN

Module without main procedure

n/a

OPENOPT OPTIMIZE OPTION

Open printer file option Optimization level Options

*{NO}INZOFL *NONE | *BASIC | *FULL *{NO}XREF *{NO}GEN *{NO}SECLVL *{NO}SHOWCOPY *{NO}EXPDDS *{NO}EXT *{NO}SHOWSKP *{NO}SRCSTMT *{NO}DEBUGIO *NOCOL | *COL *HEX | *JOB | *JOBRUN | *LANGIDUNQ | *LANGIDSHR | 'sort-table-name' *SRCMBRTXT | *BLANK | 'description' *SERIALIZE fmt{separator} *YES | *NO *USER | *OWNER

n/a n/a n/a

PRFDTA SRTSEQ

Profiling data Sort sequence table

n/a n/a

TEXT THREAD TIMFMT TRUNCNBR USRPRF

Program information text Multi-thread environment Time format Move truncated value User profile

n/a n/a n/a n/a n/a

File Description Specifications Positions or Keyword 6 7-16 17

Name Form type File name File type

Entry F Valid file name I O U C Blank P S R T F E Blank Blank A A or Blank D F E 1-32766 L Blank 1-2000 Blank Blank A P K G D T Z F Blank I T PRINTER DISK WORKSTN SPECIAL SEQ Blank Optional

RPG III 6 7-14 15

18

File designation

16

19 20 21 22 23-27 28 29-33 34

End of file File addition/unordered Sequence File format Record length Limits processing Length of key field or record address field Record address type

17 66 18 19 24-27 28 29-30 31

35

Type of file organization

32

36-42

Device

40-46

43 44-80 81-100

Reserved Keywords Comments

n/a n/a 75-80

RPG IV Keyword BLOCK COMMIT DATFMT DEVID EXTFILE EXTIND EXTMBR FORMLEN FORMOFL IGNORE INCLUDE INDDS INFDS INFSR KEYLOC MAXDEV OFLIND PASS PGMNAME PLIST PREFIX PRTCTL RAFDATA RECNO RENAME SAVEDS SAVEIND SFILE SLN TIMFMT USROPN

Name Record blocking Commitment control Date format Program device File name External indicator Member name Form length of printer file Overflow line number Ignore record format Include record format Name an indicator data structure Name a feedback data structure File exception/error subroutine Key field location Maximum number of devices for WORKSTN file Overflow indicator Do not pass indicators SPECIAL device

Entry *YES | *NO {rpg_name} fmt{separator} fieldname filename *INU1-*INU8 menbername number number recformat recformat data structure name data structure name subroutine name number *ONLY | *FILE *INOA-*INOG, *INOV, *IN01*IN99, name *NOIND program name

RPG III n/a COMIT n/a ID n/a 71-72 n/a (L) 15-17, 18-19 (L) 20-22, 23-24 IGNORE n/a n/a INFDS INFSR 35-38 NUM 33-34 PASS 54-59 PLIST n/a (E) 11-18 RECNO RENAME SAVDS IND SFILE SLN n/a 71-72

Name of parameter list to be passed plist name to program for SPECIAL file Prefix, partial rename Dynamic printer control Name of RAF data file Rename record format from externally described file Save data structure Save indicators Subfiles Start line number Time format User controlled open prefix string{:number} data structure name{:COMPAT} filename external_format_name : internal_format_name data structure name number recformat : rrnfield number fmt{separator}

Processed by relative record number fieldname

Definition Specifications Positions or Keyword Name 6 7-21 22 23 Form type Name External Description Type of Data Structure Entry D Symbolic name Blank E Blank S U Blank C DS PI PR S Blank nnnnnnn Blank nnnnnnn +|-nnnnn Blank A B C D F G I N O P S T U Z * Blank 0-30 RPG III n/a (I) 7-12, 53-58 (E) 27-32, 46-51 (I) 17 (I) 18

24-25

Type of Definition

(I) 19-20, 43

26-32 33-39

From Position To Position / Length

(I) 44-47 (I) 48-51 (E) 4042, 52-54 (I) 43

40

Internal Data Type

41-42 43 44-80 ALIGN ALT ALTSEQ ASCEND BASED CCSID CLASS CONST CONST CTDATA

Decimal Positions Reserved Keywords Align integer, unsigned and float subfields Alternating array Sort sequence Basing pointer Graphic and UCS-2 CCSID Class Constant name Read-only parameter Compile time data

(I) 52 (E) 44, 56 n/a n/a n/a

main array_name

(E) 27-32 n/a (E) 45, 57 n/a n/a n/a (I) 21-42, 43 n/a n/a

Alternate sequence options for field *NONE basing_pointer_name number | *DFT *JAVA:classname constant value

DATFMT DESCEND DIM DTAARA EXPORT EXTFLD EXTFMT

Date format Sort sequence Number of elements in array Data area name Field can be exported Rename an externally described subfield External data type

format{separator} numeric constant {data area name} {external name} field name B C F I L P R S U program name {*CL |*CWIDEN |*CNOWIDEN |{*JAVA:classname}} procedure name file_name {external name} {constant|*EXTDFT |*LIKEDS|*NULL |*USER|*JOB|*SYS} rpg_name data structure name numeric_constant

n/a (E) 45, 57 (E) 36-39 n/a n/a (I) 21-30 (E) 43, 55

EXTNAME EXTPGM EXTPROC

External file with field descriptions file_name {:format_name} External prototyped program name External prototyped procedure name File pre-run time array is loaded from Field can be imported Initialize data

(I) 21-30 n/a n/a

FROMFILE IMPORT INZ

(E) 11-18 n/a (I) 21-42

LIKE LIKEDS NOOPT OCCURS OPDESC OPTIONS OVERLAY PACKEVEN PERRCD PREFIX PROCPTR QUALIFIED STATIC TIMFMT TOFILE VALUE VARYING

Define a field like another Define a data structure like another No optimization Number of occurrences in multiple occurrence data structure Operational descriptor Parameter passing options for prototyped parameters Overlay data structure subfield Packed field has an even number of digits Number of elements per record Add, replace a prefix to externally described fields Field is a procedure pointer Subfields use qualified names Data item uses static storage, or Java method is static Time format File to write array or table data to Pass prototyped parameter by value Varying length character or graphic field

n/a n/a n/a (I) 44-47 n/a

*NOPASS *OMIT *VARSIZE *STRING *RIGHTADJ name{:pos|*NEXT}

n/a n/a n/a

numeric constant prefix string{:number}

(E) 33-35 n/a n/a n/a n/a

format{separator} file_name

n/a (E) 19-26 n/a n/a

Externally Described Files, Record Identification Entries (IX) Positions 6 7-16 17-20 21-22 Record identifying indicators Name Form type Record name Entry I Record format name Blank Blank 01-99 L1-L9, LR H1-H9 U1-U8 RT Blank Comments Optional RPG III 6 7-14 15-18 19-20

23-80 81-100

21-74 75-80

Externally Described Files, Field Entries (JX) Positions 6 7-20 21-30 31-48 49-62 63-64 65-66 67-68 69-74 Field indicators RPG field name Control level Match fields External field name Name Form type Entry I Blank Field name Blank Field name Blank L1-L9 Blank M1-M9 Blank Blank 01-99 H1-H9 U1-U8 RT Blank Comments Optional RPG III 6 7-20 21-30 31-52 53-58 59-60 61-62 63-64 65-70

75-80 81-100

71-75 75-80

Program Described Files, Record Identification Entries (I) Positions 6 7-16 16-18 17-18 Name Form type File name Logical relationship Sequence Entry I Valid file name AND or OR Any two alphabetic characters Any two-digit number Blank 1 N Blank O Blank 01-99 L1-L9, or LR H1-H9 U1-U8 RT ** Blank 1-32766 Blank N C Z D Any character Blank Comments Optional RPG III 6 7-14 14-16 15-16

19

Number

17

20 21-22

Option Record identifying indicators

18 19-20

23-27, 31-35, 39-43 28, 36, 44 29, 37, 45

Position

21-24, 28-31, 35-38 25, 32, 39 26, 33, 40

Logical relationship Code part

30, 38, 46 47-80 81-100

Character

27, 34, 41 42-74 75-80

Program Described Files, Field Description Entries (J) Positions 6 7-30 31-34 35 36 Data attributes Date/Time separator Data format Name Form type Entry I Blank *VAR or Date/Time external format Any Character Blank A B C D F G I RPG III 6 7-42 n/a n/a 43

L N P R S T U Z 37-41 42-46 47-48 49-62 63-64 65-66 67-68 From To Decimal positions Field name Control Level Match fields Field record relation 1-32766 1-32766 Blank 0-30 Symbolic name Blank L1-L9 Blank M1-M9 Blank 01-99 L1-L9 MR U1-U8 H1-H9 RT Blank 01-99 H1-H9 U1-U8 RT Blank Comments Optional 44-47 48-51 52 53-58 59-60 61-62 63-64

69-74

Field indicators

65-70

75-80 81-100

71-74 75-80

Calculation Specifications Summary Chart (C) Positions 6 7-8 Name Form type Control level Entry C Blank L0 L1-L9 LR SR AN, OR Blank 01-99 KA-KN, KP-KY L1-L9 LR MR H1-H9 RT U1-U8 OA-OG, OV Symbolic name or literal Operation code and extender Symbolic name or literal Field name Blank 1-30 1-32767 Blank 0-30 Blank 01-99 KA-KN, KP-KY H1-H9 L1-L9 LR OA-OG, OV U1-U8 RT Blank Comments RPG III 6 7-8

9-11

Conditioning indicators

9-17

12-25 26-35 36-49 50-63 64-68

Factor 1 Operation and extender Factor 2 Result field Field length

18-27 28-32, 53 33-42 43-48 49-51

69-70 71-76

Decimal positions Resulting indicators

52 54-59

77-80 81-100

Reserved Comments

n/a 60-80

Calculation Specifications Extended Factor 2 Summary Chart (CX) Positions 6 7-8 Name Form type Control level Entry C Blank L0 L1-L9 LR SR AN, OR Blank 01-99 KA-KN, KP-KY RPG III n/a n/a

9-11

Conditioning indicators

n/a

L1-L9 LR MR H1-H9 RT U1-U8 OA-OG, OV 12-25 26-35 36-80 Factor 1 Operation Extended Factor 2 Reserved Operation code and extender Expression n/a n/a n/a

Free-Form Calculation Specifications Summary Chart Positions 6-7 7 8-80 Start or end free-form specification Free-form calculation statement Comments Name Entry Blank /FREE or /END-FREE delimiter Operation code and extendor, expression ended with a semicolon (;) // RPG III n/a n/a n/a

6-80

n/a

Externally Described Files, Record Identification and Control Entries (O) Positions 6 7-16 16-18 17 Name Form type Record name Logical relationship Type Entry O Valid record-format name AND or OR H or D T E R ADD DEL Blank 01-99 KA-KN, KP-KY L1-L9 H1-H9 U1-U8 MR LR RT 1P Record group name Blank Optional RPG III 6 7-14 14-16 15

18 18-20 21-29

Release Record addition field Output indicators

16 16-18 23-31

30-39 40-80 81-100

EXCEPT name Reserved Comments

32-37 38-74 75-80

Externally Described Files, Field Description and Control Entries (P) Positions 6 7-20 21-29 30-43 Name Form type Reserved Field output indicators Field name Entry O Blank See output indicators Valid field name RPG III 6 7-22 23-31 32-37

*ALL 44 45 46-80 81-100 Reserved Blank after Reserved Comments Blank Blank B Blank Optional 38 39 40-74 75-80

Program Described Files, Record Identification and Control Entries (Record Line) (OD) Positions 6 7-16 16-18 17 Name Form type File name AND/OR Type Entry O Valid file name AND or OR H or D T E Blank F R ADD DEL Blank 01-99 KA-KN, KP-KY L1-L9 H1-H9 U1-U8 OA-OG, OV MR LR RT 1P Record group name 0 or blank 1-255 0 or blank 1-255 1-255 1-255 Blank Optional RPG III 6 7-14 14-16 15

18

Fetch overflow F Release ADD/DEL Output indicators

16

18-20 21-29

16-18 23-31

30-39 40-42 43-45 46-48 49-51 52-80 81-100

EXCEPT name Space before Space after Skip before Skip after Reserved Comments

32-37 17 18 19-20 21-22 38-74 75-80

Program Described Files, Field Description and Control Entries (Field Line) (P) Positions 6 7-21 21-29 30-43 Name Form type Reserved Field output indicators Field name Entry O Blank See output indicators Valid field name RPG III 6 7-22 23-31 32-37

PAGE, PAGE1-PAGE7

UDATE, UDAY, UMONTH, UYEAR, *DATE, *DAY,

*MONTH, *YEAR

*PLACE *IN, *INxx, *IN(xx) 44 Edit code Blank 1-4 5-9 A-D, J-Q, X, Y, Z Blank B Blanks, +nnnn, -nnnn, nnnn 38

45 47-51

Blank after End position in output record

39 40-43

K1-K10 52 Data Format Blank A B C D F G I L N P R S T U Z Constant, Edit word, Data attribute, Format name Optional 44

53-80 81-100

Constant, Edit word, Data attribute, Format name Comments

45-70 75-80

Procedure Specification (PR) Positions or Keyword 6 7-21 24 44-80 81-100 EXPORT

Name Form type Name Begin/End Procedure Keywords Comments Procedure can be exported

Entry P Symbolic name BE Optional

You might also like