Re: Trying To Read Input Spoolfiles Problem - Hewlett Packard

This is a discussion on Re: Trying To Read Input Spoolfiles Problem - Hewlett Packard ; In a message dated 8/3/2008 11:15:40 P.M. Pacific Daylight Time, Guenter.Kuhn@ssd-it.ch writes: use HPFopen to open input spoolfiles with the following options: 2: Formal File Designator %Innn.IN.HPSPOOL% 3: Domain: 1 (permanent) 9: Dissallow file: 1 29: Priv-Level: 2 works perfectly ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Re: Trying To Read Input Spoolfiles Problem

  1. Re: Trying To Read Input Spoolfiles Problem


    In a message dated 8/3/2008 11:15:40 P.M. Pacific Daylight Time,
    Guenter.Kuhn@ssd-it.ch writes:

    use HPFopen to open input spoolfiles with the following options:

    2: Formal File Designator %Innn.IN.HPSPOOL%
    3: Domain: 1 (permanent)
    9: Dissallow file: 1
    29: Priv-Level: 2

    works perfectly since many years. If you work with input spoolfile



    Nice try but it won't work for me. My problem isn't the FOPEN, it's the
    FREAD that isn't reading the
    records... The file is being FOPENed ok but the FREAD is failing.

    However, as my program is riddled with calls to FOPEN, mixing and matching
    is a *big* no-no. Why?
    Because, as I discovered many eons ago, FOPEN and HPFOPEN can return the
    SAME file number on
    different files!! OUCH!

    I don't know if HP ever fixed this problem, but I doubt it and if it hasn't
    been fixed, then I doubt they ever will
    fix it now.........

    Life in the fast lane......

    Brian.



    **************Looking for a car that's sporty, fun and fits in your budget?
    Read reviews on AOL Autos.
    (http://autos.aol.com/cars-BMW-128-20...00050000000017 )

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


  2. Re: Trying To Read Input Spoolfiles Problem

    Brian Donaldson wrote:
    >
    > In a message dated 8/3/2008 11:15:40 P.M. Pacific Daylight Time,
    > Guenter.Kuhn@ssd-it.ch writes:
    >
    > use HPFopen to open input spoolfiles with the following options:
    >
    > 2: Formal File Designator %Innn.IN.HPSPOOL%
    > 3: Domain: 1 (permanent)
    > 9: Dissallow file: 1
    > 29: Priv-Level: 2
    >
    > works perfectly since many years. If you work with input spoolfile


    Just this morning I ran PRINTSPF in debug and found that HPFOPEN
    is called
    51 "I2.IN.HPSPOOL" filename
    3 3 domain
    75 $401000A1 ... reserved (No idea)
    9 1 NoFeq
    29 2 Priv-level-2

    75 is undocumented, at least from what I've seen.

    I haven't been able in my C test to get my FOPEN to open this file.
    Still get PRIVILEGED FILE VIOLATION (FSERR 45)
    sf = FOPEN ( name, 026107, 00300 );

    (started with 026105, and 0345, varying LOCK, SHR, MULTI, GMULTI,
    READ options).

    (MPE 6.0 pp2)
    Keven

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


  3. Re: Trying To Read Input Spoolfiles Problem

    Brian theorizes...

    ....
    > However, as my program is riddled with calls to FOPEN, mixing
    > and matching is a *big* no-no. Why?
    > Because, as I discovered many eons ago, FOPEN and HPFOPEN can
    > return the SAME file number on different files!! OUCH!
    >
    > I don't know if HP ever fixed this problem, but I doubt it
    > and if it hasn't been fixed, then I doubt they ever will fix
    > it now.........
    >
    > Life in the fast lane......
    >
    > Brian.

    ....

    I feel a need to correct this misinformation so that no one will mistakenlyassume it to be true. FOPEN and HPFOPEN are two different interfaces to the same routines (one routine creates new files, and the other opens existing files) that perform the file open operation on MPE/iX (or XL). Calling FOPEN or HPFOPEN produces exactly the same result on exactly the same set of data structures on exactly the same set of files. FOPEN's parameter interface is restricted and therefore does not allow for easy expansion of new options. HPFOPEN's paramter interface was designed to be highly expansible andflexible. There are a lot of open options that HPFOPEN supports that FOPENcan't, but the things that they both do are exactly identical.

    There are no incompatiblities or issues in mixing calls to FOPEN or HPFOPEN.. The only way that you can see the same file number returned from two different calls to these intrinsics (within the same process) is if the processcloses the file number after the first open and before the second. If thisis unintended, it is usually necessary to debug the application looking for uninitialized variables or other user program logic errors.

    I hope this is helpful.

    Take Care,
    Craig

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


+ Reply to Thread