home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 31
/
CDASC_31_1996_juillet_aout.iso
/
vrac
/
ledwes.zip
/
COBOL.L
< prev
next >
Wrap
Text File
|
1996-02-17
|
3KB
|
139 lines
c:\c700\bin\QH
-rb
c:\c700\bin\win31wh.hlp
.
0
*
.esq
IDENTIFICATION DIVISION.
*
PROGRAM-ID. nombre.
AUTHOR. nombre.
DATE-WRITTEN. fecha.
REMARKS. comentarios.
*
*
ENVIRONTMENT DIVISION.
*
CONFIGURATION SECTION.
OBJECT-COMPUTER. ?????????.
DECIMAL-POINT IS COMMA.
*
INPUT-OUTPUT SECTION.
FILE-CONTROL.
*
I-O-CONTROL.
*
*
DATA DIVISION.
*
FILE SECTION.
*
WORKING-STORAGE SECTION.
*
PROCEDURE DIVISION.
.ss
SELECT file secuencial
ASSIGN TO xxxxxxxxxxxxx
ORGANIZATION IS SEQUENTIAL
ACCESS MODE IS SEQUENTIAL.
*
.si
SELECT file indexado
ASSIGN TO xxxxxxxxxxxxx
ORGANIZATION IS INDEXED
ACCESS MODE IS SEQUENTIAL | RANDOM | DYNAMIC
RECORD KEY IS campo.
*
.sr
SELECT file relativo
ASSIGN TO xxxxxxxxxxxxx
ORGANIZATION IS RELATIVE
ACCESS MODE IS
SEQUENTIAL [RELATIVE KEY IS campo].
RANDOM | DYNAMIC RELATIVE KEY IS campo.
*
.fd
FD file
BLOCK CONTAINS [aaaa TO] bbbb CHARACTERS | RECORDS
RECORD CONTAINS [aaaa TO] bbbb CHARACTERS
LABEL RECORDS STANDARD | OMMITED
DATA RECORD IS nombre.
*
.pr
procedure.
sentencias
.a
ADD id1 id2 ... TO idr1 ROUNDED idr2 ROUNDED.
.ag
ADD id1 id2 ... GIVING idr1 ROUNDED idr2 ROUNDED.
.ac
ADD CORRESPONDING id1 TO id2 ROUNDED.
.cl
CLOSE file WITH NO REWIND | LOCK.
.c
COMPUTE id1 ROUNDED id2 ROUNDED ... = expresi≤n.
.di
DISPLAY id1 id2 ... UPON CONSOLE.
.d
DIVIDE id1 INTO | BY id2 GIVING res ROUNDED REMAINDER resto.
.i
IF condici≤n
sentencias | NEXT SENTENCE
ELSE
sentencias | NEXT SENTENCE.
NOTE fin if.
.m
MOVE id TO idr1 idr2 ... .
.mc
MOVE CORRESPONDING id TO idr.
.x
MULTIPLY id1 BY id2 ROUNDED id3 ROUNDED ... .
.xg
MULTIPLY id1 BY id2 GIVING idr1 ROUNDED idr2 ROUNDED ... .
.o
OPEN INPUT | OUTPUT | I-O | EXTEND file REVERSED | WITH NO REWIND.
.p
PERFORM procedure [THROUGH procedure].
.pt
PERFORM procedure [THROUGH procedure] xxxxx TIMES.
.pu
PERFORM procedure [THROUGH procedure] UNTIL condici≤n.
.pv
PERFORM procedure [THROUGH procedure] VARYING xxx FROM yyy BY zzz UNTIL condici≤n.
.r
READ file NEXT RECORD [INTO campo] AT END sentencia.
.rr
READ file RECORD [INTO campo] [KEY IS campo] [INVALID KEY sentencia].
.rw
REWRITE registro [FROM campo] [INVALID KEY sentencia].
.st
START file KEY IS =>< campo].
.s
SUBTRACT id1 id2 ... FROM idr1 ROUNDEN idr2 ROUNDED ... .
.sg
SUBTRACT id1 id2 ... FROM idn GIVING idr1 ROUNDED idr2 ROUNDED ... .
.sc
SUBTRACT CORRESPONDING id1 FROM id2 ROUNDED.
.wi
WRITE registro FROM campo AFTER | BEFORE id LINES AT EOP sentencia.
.w
WRITE registro FROM campo.
.wr
WRITE registro FROM campo INVALID KEY sentencia.
.se
SEARCH id1 [VARYING id2]
[AT END sentencia]
WHEN condici≤n sentencia | NEXT SENTENCE ...
NOTE fin search.
.sa
SEARCH ALL id
[AT END sentencia]
WHEN condici≤n [AND condici≤n]... sentencia | NEXT SENTENCE.
NOTE fin search.
..
<...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8....+....9....+....0....+....1....+....2....+.