B Glossary of Terms
Alphabetic Data Item
A data item whose
PICTURE
clause allows it to contain only upper- and/or lower-case letters. 6.9.37 PICTURE.Alphanumeric Data Item
A data item whose
PICTURE
clause allows it to contain absolutely any character whatsoever. 6.9.37 PICTURE. Group items ( 2.1.7 Structured Data) are also implicitly considered to be alphanumeric data items.Alphanumeric Literal
A string of characters enclosed within a pair of quotation marks (’
"
‘) or apostrophes (’'
‘). 2.1.19.2 Alphanumeric Literals.Called Program
Another way to refer to a subprogram. Note that a called program may also be a calling program.
Calling Program
A program that executes a subprogram. Note that a calling program may also be a called program.
Collating Sequence
The sequence in which the characters that are acceptable to a computer are ordered for purposes of all types of sorting, merging, comparing, and processing. GnuCOBOL programs may utilize standard character-set collating sequences (such as that defined by the ASCII or EBCDIC character sets) or programmer-defined custom sequences as specified in the OBJECT-COMPUTER paragraph (section 4.1.2) and defined in the SPECIAL-NAMES paragraph (section 4.1.4).
Compilation Group
The collection of all compilation units being compiled by a single execution of the GnuCOBOL compiler.
Compilation Unit
A single source file being compiled by the GnuCOBOL compiler. A compilation unit may contain one or more programs.
Control Break
An event that is triggered when a control field on an RWCS-generated report changes value. It is these events that trigger the generation of control heading and control footing groups.
Control Field
A field of data being presented within a detail group; as the various detail groups that comprise the report are presented, they are presumed to appear in sorted sequence of the control fields contained within them. As an example, a department-by-department sales report for a chain of stores would probably be sorted by store number and – within like store numbers – be further sorted by department number. The store number will undoubtedly serve as a control field for the report, allowing control heading groups to be presented before each sequence of detail groups for the same store and control footing groups to be presented after each such sequence.
Control Footing
A report group that appears immediately after one or more detail groups of an RWCS-generated report. Such are produced automatically as a result of a control break. This type of group typically serves as a summary of the detail group(s) that precede it, as might be the case on a sales report for a chain of stores, where the detail groups documenting sales for each department (one department per detail group) from the same store might be followed by a control footing that provides a summation of the department-by-department sales for that store.
Control Heading
A report group that appears immediately before one or more detail groups of an RWCS-generated report. Such are produced automatically as a result of a control break. This type of group typically serves as an introduction to the detail group(s) that follow, as might be the case on a sales report for a chain of stores, where the detail groups documenting sales for each department (one department per detail group) from the same store might be preceded by a control heading that states the full name and location of the store.
Control Hierarchy
The natural hierarchy of control breaks within a RWCS-controlled report based upon the manner in which the data the report is being generated from is sorted.
Copybook
A segment of program code that may be utilized by multiple programs simply by having that program use the
COPY
statement to import that code into the program. Although similar to the “include” facility present in many other programming languages, the COBOL copybook mechanism is actually considerably more powerful. 2.1.6 Copybooks, for a general discussion. 3.2 COPY, for the specifics of theCOPY
statement.Data Item
A contiguous area of storage within the memory space of a program that may be referenced, by name, in a COBOL program. Other programming languages use the term variable, property or attribute to describe the same concept. 2.1.7 Structured Data.
Detail Group
A report group that contains the detailed data being presented for the report.
Detail Report
An RWCS-generated report to which at least one type of detail group is presented.
Division
A collection of zero, one, or more sections of paragraphs, called the division body, that are formed and combined in accordance with a specific set of rules. Each division consists of the division header and the related division body. There are four divisions in a GnuCOBOL program: Identification, Environment, Data, and Procedure (coded in that sequence). 2.1.17 Program Structure.
Dynamic Subprogram
A subprogram whose executable object code is contained in a different executable file as its calling program. Dynamic subprograms are therefore loaded into memory as needed.
Elementary Item
A data item that isn’t itself comprised of other data items. 2.1.7 Structured Data.
Entry-point
A spot in the procedure division where a program may begin execution when it is executed from the operating system, invoked as a user-defined function or called by another program.
Every program has at least one entry-point — known as the primary entry-point — which corresponds to the first executable statement in the procedure division following the declaratives area, if any.
Additional entry-points may be defined via the
ENTRY
statement ( 7.8.14 ENTRY).Entry-point Name
Every entry-point has a name. That name must be unique for all programs that comprise an executable program. Entry-point names are defined using a subroutine’s
PROGRAM-ID
paragraph, a user-defined function’sFUNCTION-ID
paragraph or viaENTRY
( 7.8.14 ENTRY) statements coded in a subprogram’s procedure division.Executable File
The GnuCOBOL compiler can create operating-system appropriate files that may be executed directly from the operating system environment. On Windows systems, these will be
.exe
files whereas on UNIX systems they will have no specific extensions. The compiler’s-x
switch is used to create executable files. Only main programs should be compiled in this manner.Execution Thread
The complete set of executable code that is run during the execution of a program. This includes the main program as well as all executed subprograms, including those that are both dynamically and statically loaded.
Figurative Constants
GnuCOBOL, like other COBOL implementations, supports a number of reserved words that may be used to represent a specific literal value. These are known as figurative constants. 2.1.19.3 Figurative Constants, for more information.
Fixed Format Mode
A mode of the GnuCOBOL compiler’s operation where source statements are constrained to meeting the pre-2002 standard of limiting COBOL statements to 80 columns, with various columns having limitations as to what sort of COBOL syntax could be specified in them. 2.1.16 Format of Program Source Lines, for more information.
Free Format Mode
A mode of the GnuCOBOL compiler’s operation where source statements are allowed to be as long as 255 characters, with no restrictions or requirements as to in which columns various syntax elements must appear. 2.1.16 Format of Program Source Lines, for more information.
Group Item
A hierarchical data structure where the group item — itself a data item — actually consists of two or more other contiguously allocated data items. For example,
Employee-Name
could be a 35-character data item consisting of a 20-characterLast-Name
data item followed by a 14-characterFirst-Name
and a 1-characterMiddle-Initial
. 2.1.7 Structured Data.Hexadecimal Alphanumeric Literal
These are alphanumeric literals whose character sequence is specified by hexadecimal value. These literals are formed by a quote- or apostrophe-delimited sequence of an even number of hexadecimal digits (upper- or lower-case), prefixed with the letter ‘
X
‘ (also upper- or lower-case). For example, the character string “Demo
“ could be specified as the hexadecimal alphanumeric literalX'44656D6F'
, assuming the ASCII character set. 2.1.19.2 Alphanumeric Literals.Hexadecimal Numeric Literal
A numeric literal whose value is specified by hexadecimal value. These literals are formed by a quote- or apostrophe-delimited sequence of from 1 to 16 hexadecimal digits (upper- or lower-case), prefixed with the letter ‘
H
‘ (also upper- or lower-case). For example, the number 123456 could be specified as the hexadecimal numeric literalH'01E240'
. 2.1.19.1 Numeric Literals.Identifiers
These are data items a COBOL program will be working with. The vast majority of identifiers are defined by the user (programmer) while a few are pre-defined by the GnuCOBOL compiler. Identifiers pre-defined by the compiler are referred to as special registers. Other programming languages generally refer to identifiers as “variables”.
Imperative Statement
Either a statement that begins with a non decision-making verb and specifies an unconditional action to be taken or a conditional verb such as
IF
orEVALUATE
, delimited by its explicit scope terminator (such asEND-IF
orEND-EVALUATE
). An imperative statement can consist of a sequence of imperative statements.Intrinsic Function
A built-in routine that accepts arguments and returns a value; syntactically, these may be used most places where GnuCOBOL identifiers are valid. E List of Intrinsic Functions, for documentation on all the GnuCOBOL intrinsic functions.
Level Number
A 1- or 2-digit number that indicates the hierarchical position of a data item in a group item or the special properties of a data description entry.
Level numbers in the range 1 through 49 indicate the position of a data item in the hierarchical structure of a logical record. Level numbers in the range 1 through 9 can be written either as a single digit or as a zero followed by the significant digit.
Level numbers 66, 77, 78 and 88 identify special properties of a data description entry.
Literal
A generic term used for a constant value coded in a program that may be either a numeric literal or an alphanumeric literal.
Main program
A program that is executed directly from an operating system or shell event. Main programs are not executed from other programs (i.e. they are not called programs).
National Character set
A character set that supports symbols using other than the traditional Roman alphabet symbols used by the ASCII character set. Typically, such a character set uses a UTF-16 (i.e. 16 bits-per-character) encoding of the Unicode character set.
Support for national character sets in GnuCOBOL is currently only partially implemented, and the compile- and run-time effect of using the
N
symbol in aPICTURE
( 6.9.37 PICTURE) clause to define a field as containing national characters is the same as ifX(2)
had been coded, with the additional effect that such a field will qualify as aNATIONAL
orNATIONAL-EDITED
field on anINITIALIZE
( 7.8.24 INITIALIZE) statement.Numeric Data Item
A data item whose
PICTURE
clause allows it to contain only the numeric digit characters0
-9
(signed or unsigned), or a data item whosePICTURE
/USAGE
combination allow it to contain actual binary numbers in integer, fixed-point, floating-point or packed-decimal format. Numeric data items are the only ones that may be used as table subscripts or as source arguments on arithmetic statements.PICTURE
( 6.9.37 PICTURE), orUSAGE
( 6.9.61 USAGE).Numeric Edited Data Item
An otherwise numeric data item whose
PICTURE
( 6.9.37 PICTURE) clause also contains any of the editing symbols ‘$
‘, ‘*
‘, ‘+
‘, ‘,
‘, ‘-
‘, ‘.
‘, ‘/
‘, ‘0
‘ (zero), ‘B
‘, ‘CR
‘, ‘DB
‘ or ‘Z
‘. Numeric edited data items are not eligible to serve as table subscripts or source arguments on arithmetic statements.Numeric Literal
A numeric constant. 2.1.19.1 Numeric Literals.
Page Footing
A report group that appears at the bottom of every page of an RWCS-generated report. Information typically found within such a report group might be:
The date the report was generated
The current page number of the report
Page Heading
A report group that appears at the top of every page of an RWCS-generated report. Information typically found within such a report group might be:
A title for the report
The date the report was generated
The current page number of the report
Column headings describing the fields within the detail group(s)
Primary Entry-Point
See entry-point.
Procedure
All executable code statements within a single procedure division paragraph or section.
Procedure name
A programmer-defined section or paragraph name in the procedure division assigned to a procedure. Procedure names serve as a means by which a statement may refer to the statements that follow the procedure name.
Program
A GnuCOBOL main program or subprogram.
Qualification
The process of establishing a unique reference to a data item whose name is duplicated in a program. This takes the form of using the duplicated data name and the name of any of its parent data items, connected by
OF
orIN
such that the combination of those two data names is unique within the program.Record
A group item that is not part of a higher-level group item. 6.1 Data Definition Principles. An elementary item with a level number of 01 can also be referred to as a record if its definition occurs in the file section, provided that its definition does not include the
CONSTANT
attribute. 6.2.2 FILE-SECTION-Data-Item.Report Footing
A report group that occurs only once in an RWCS-generated report — as the very last presented report group of the report. These typically serve as a visual indication that the report is finished.
Report Group
One or more consecutive lines on a report that serve a common informational purpose or function. For example, lines of text that are displayed at the top or bottom of every printed page of a report.
Report Heading
A report group that occurs only once in an RWCS-generated report — as the very first presented report group of the report. These typically serve as an introduction to the report.
Reserved Word
A word coded in a GnuCOBOL program without any quote or apostrophe characters around it (which would have transformed that sequence of characters into a literal string) which has a very specific meaning to the compiler. 2.1.1 Language Reserved Words, for a general discussion of the concept. Appendix C for a complete list of GnuCOBOL reserved words.
Sentence
An arbitrarily long sequence of statements terminated by a period.
Special Registers
Special data items that are automatically defined for your use by the GnuCOBOL compiler. 7.7 Special Registers, for a complete list.
Statement
A single executable COBOL instruction. All statements start with a verb (
DISPLAY
,IF
,MOVE
, …) which is followed by the operands and additional syntax elements that describe the actions to be performed.Static Subprogram
A subprogram whose executable object code is part of the same executable file as its calling program. Static subprograms are therefore loaded into memory at the same time as their caller.
Subprogram
A program invoked directly by another program in such a manner that it may return control back to the other program, directly back to the point where the subprogram was invoked.
Subroutine
A subprogram executed from another via a GnuCOBOL
CALL
( 7.8.5 CALL) statement (or the equivalent in whatever programming language that other program was written in).Summary Report
An RWCS-generated report to which no detail groups are presented.
User-Defined Function
A subprogram written in GnuCOBOL that is executed in a syntactically-similar manner to that by which the various built-in intrinsic functions are executed.
User-Defined Names
Either the name of an identifier or a procedure in the program. GnuCOBOL limits user-defined names to a maximum of 31 characters taken from the set of numeric digits, upper- and lower-case letters, hyphens and underscores. A user-defined name may neither begin nor end with a hyphen or underscore. User-defined names used as file names may additionally not begin with a digit although - unlike many other programming languages - user-defined names used as identifiers or procedure names may.
Verb
The first reserved word of a COBOL statement.
Zero-Delimited Alphanumeric Literals
An alphanumeric literal prefixed with an upper- or lower-case ‘
Z
‘ character — for example,Z'ABC'
. These literals are one character longer than the value within apostrophes or quotes would make them appear. The extra character (the last character) will be a null character (comprised entirely of zero bits). These literals are ideal when defining or assigning values to alphanumeric data items that will be passed as arguments to a C subroutine. 2.1.19.2 Alphanumeric Literals.