Thank you all for input. I still need help, here... I tried the following,
per suggestions on the listserv:
* fd IN-FILE.
+1 01 IN-RECORD.
+2 05 IN-A pic x(6).
+3 05 IN-TOTAL pic s9(27) comp-3.
but when I tried to compile it using COB85XLK COBTEST,COBTEST1,$NULL I
received this:
PAGE 0001 COBOL II/iX HP31500A.04.19 [85] Copyright Hewlett-Packard CO.
1987
LINE # SEQ # COL ERROR SEV TEXT
----------------------------------------------------------------------------
--
00030 002022 46 122 Q MORE THAN 18 DIGITS IN A NUMERIC PICTURE.
0 ERROR(s), 1 QUESTIONABLE, 0 WARNING(s)
DATA AREA IS 6FC BYTES.
CPU TIME = 0:00:00. WALL TIME = 0:00:00.
End Run
END OF COMPILE
HP Link Editor/iX (HP30315A.05.26) Copyright Hewlett-Packard Co 1986
LinkEd> link ;to=COBTEST1
END OF LINK
And then, when I tried run the program:
RUN COBTEST1
Filename: INFILE
File status is 39
File's fixed attributes differ from program [39] RECORD SIZE (COBERR 648
)
Program file: COBTEST1.EBEN.AIHBETA
END OF FILE (FSERR 0)
+-F-I-L-E---I-N-F-O-R-M-A-T-I-O-N---D-I-S-P-L-A-Y+
! FILE NAME IS Z1.EBEN.AIHBETA !
! FOPTIONS: SYS,ASCII,FORMAL,F,NOCCTL,FEQ !
! NOLABEL !
! AOPTIONS: INPUT,NOMR,NOLOCK,DEF,BUF,NOMULTI !
! WAIT,NOCOPY !
! DEVICE TYPE: 3 DEVICE SUBTYPE: 8 !
! LDEV: 40 DRT: 8 UNIT: 0 !
! RECORD SIZE: 20 BLOCK SIZE: 1280 (BYTES) !
! EXTENT SIZE: 20 MAX EXTENTS: 1 !
! RECPTR: 0 RECLIMIT: 28 !
! LOGCOUNT: 0 PHYSCOUNT: 0 !
! EOF AT: 28 LABEL ADDR: %00000000000 !
! FILE CODE: 1084 ULABELS: 12 !
! FILE OWNER: MGR.AIHBETA !
! PHYSICAL STATUS: 0000000000000000 !
! ERROR NUMBER: 0 RESIDUE: 0 !
! BLOCK NUMBER: 0 NUMREC: 64 !
+------------------------------------------------+
**** COB_QUIT 648 ****
ABORT: COBTEST1.EBEN.AIHBETA
NM SYS a.00aa1288 dbg_abort_trace+$24
NM USER 18c.00f16394 COB_QUIT+$b8
NM PROG 3d1.0000599c _start+$12c
Program terminated in an error state. (CIERR 976)
End Run
-----Original Message-----
From: John Zoltak [mailto:[log in to unmask]]
Sent: Thursday, October 14, 1999 7:55 AM
To: [log in to unmask]; [log in to unmask]
Subject: RE: [HP3000-L] HOW TO DEFINE P28 field in COBOL
WORKING-STORAGE?
Eben,
05 in-total pic s9(27) comp-3. This assumes decimal place the the end. If
you're using dollars and cents then it would be pic s9(25)v9(2) comp-3.
John Zoltak
North American Mfg Co
Cleveland Ohio
> -----Original Message-----
> From: Eben Yong [mailto:[log in to unmask]]
> Sent: Thursday, October 14, 1999 10:35 AM
> To: [log in to unmask]
> Subject: [HP3000-L] HOW TO DEFINE P28 field in COBOL WORKING-STORAGE?
>
>
> Hi folks,
>
> Here's the SUPRTOOL file layout:
>
> File: Z1.EBEN.AIHBETA (SD Version B.00.00)
> Entry: Offset
> A X6 1
> ST-TOTAL-1 P28 7
> Limit: 28 EOF: 28 Entry Length: 20 Blocking: 64
>
> how do I define the ST-TOTAL-1 field in the COBOL program?
>
> +7 file-control.
> +8 select IN-FILE assign to "INFILE".
> +9 select OUT-FILE assign to "OUTFILE".
> 10 data division.
> 11 file section.
> 12 fd IN-FILE.
> 13 01 IN-RECORD.
> 14 05 IN-A pic x(6).
> 15 05 IN-TOTAL pic ?????????.
> 16
>
|