HP3000-L Archives

May 2008, Week 4

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Edwin Clements <[log in to unmask]>
Reply To:
Edwin Clements <[log in to unmask]>
Date:
Tue, 27 May 2008 21:26:46 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (72 lines)
If I am figuring this correctly, you have a COBOL
program with a file of some kind with a File Status
data item defined as PIC XX, is that correct?

And you are getting a "9" in the first byte, and
something that translates to a non-numeric character
in the 2nd byte?  

What you need to do is this:

Define your file status as follows:  (use any data
names you want as long as the byte positions are
correct):

01  FILE-FILE-STATUS.   
    05  FILE-STATUS-A            PIC XX.
    05  FILE-STATUS-B REDEFINES FILE-STATUS-A.
        10  FILE-STATUS-B1       PIC X.
        10  FILE-STATUS-B2       PIC X.

Then define another data item as follows:

01  FSTAT-DISPLAY-ITEM. 
    05  DISP-ITEM-A.
        10  DISP-ITEM-A1       PIC X VALUE LOW-VALUES.
        10  DISP-ITEM-A2       PIC X.
    05  DISP-ITEM-B REDEFINES DISP-ITEM-A   
            PIC S9(4) COMP.

Then, when you get a "9" in FILE-STATUS-B1, you will
move FILE-STATUS-B2 TO DISP-ITEM-A2, then do a display
statement to display DISP-ITEM-B.  This will give you
the file system error number which you can look up in
the MPE error manual which will tell you exactly what
is wrong.  

This is a little tricky and not explained as clearly
as it could be in the COBOL manual.  

                     Edwin Clements


--- ianne <[log in to unmask]> wrote:

> Date:         Tue, 27 May 2008 23:19:55 -0400
> From:         ianne <[log in to unmask]>
> Subject: [HP3000-L] file status error number 9
> To:           [log in to unmask]
> 
> Hi,
> 
> Can anyone help and enlighten me with the file error
> I'm encountering - file 
> status 9?
> 
> Any help is very much appreciated. =)
> 
> Thanks!
> 
> * To join/leave the list, search archives, change
> list settings, *
> * etc., please visit
> http://raven.utc.edu/archives/hp3000-l.html *
> 



      

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2