Thank you for all your helpful suggestions.

I am now looking at creating a VOC pointer as Kevin suggests below.
Actually I'll need to create two pointers one for the "TEST" account and
another for the "LIVE" account.

I had originally tried the PATH:FILE syntax before I found out that the
file needed to exist before it could be opened. So I went to the other
syntax hoping to resolve the non-existant file issue.

Here is the current function without the VOC pointer.

        GOSUB GET.MTR.COUNTER
        MTR.REC="MTR":OCONV(DATE(),"D2/"):OCONV(MTR.CTR,"MR%4"):".ROW"
        CONVERT "/" TO "" IN MTR.REC
        MTR.FILE.PATH='/tmp/MFG.DATA.IPS'
        IF @PATH = "/ud/TEST" THEN
                MTR.FILE.PATH=MTR.FILE.PATH:'.TEST'
        END
        MTR.FILE.PATH=MTR.FILE.PATH:'/tmp/'
        OPENSEQ  MTR.FILE.PATH:MTR.REC TO F.MTR.ROW.FILE ELSE
                EXECUTE '!touch ':MTR.FILE.PATH:MTR.REC
                OPENSEQ  MTR.FILE.PATH:MTR.REC TO F.MTR.ROW.FILE ELSE 
                        CALL SB.DISP(3,"TROUBLE OPENING
":MTR.FILE.PATH:MTR.REC:" [E":STATUS():"]")
                        GO PGM.EXIT
                END
        END
        WRITESEQ LASTREC APPEND ON F.MTR.ROW.FILE ELSE 
                CALL SB.DISP(3,"TROUBLE WRITING TO
":MTR.FILE.PATH:MTR.REC" [E":STATUS():"]")
                GO PGM.EXIT
        END
        CLOSESEQ F.MTR.ROW.FILE
        RETURN

Thanks again.


On Wed, 2006-01-04 at 10:35 -0700, Kevin King wrote:

> I've actually had problems with various versions of Unidata and
> CLOSESEQ releasing the file when opening a full path.  Opening under a
> VOC DIR-pointer has never exhibited that problem, so I'd recommend the
> VOC pointer approach over using a full path.
> 
> -Kevin
> [EMAIL PROTECTED]
> http://www.PrecisOnline.com
> -------
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to