You mean you want to loop on the checking *until* the lock is released and then 
write?
So this is for a job interview?

DOLOOP = 0
LOOP
    READU ITSLOCKEDJIM FROM Y,Z LOCKED
        DOLOOP = 1
    END
UNTIL NOT(DOLOOP) DO
    SLEEP 10; *Let the system catch its breath
REPEAT
WRITE X ON Y,Z ELSE CRT 'HELP ME! HELP ME!'

 

 

 

-----Original Message-----
From: Jon Wells <jwaytwe...@yahoo.com>
To: U2-Users <U2-Users@listserver.u2ug.org>
Sent: Wed, Feb 6, 2013 1:53 pm
Subject: [U2] Record locks (Unidata 7.2)


Hi all,

I have not looked at the world of record locks since my R83 Pick days.  I'm 
hoping to add the ability for the program I'm working on to:

        * Check if a record is locked
        * Wait until the lock is removed
        * Once the lock is removed, or if the record is not locked:
        * Lock the record
        * Perform the WRITE statement
I'm hoping someone can share an example of how to accomplish this in UniBasic.  


Thank you,


Jon Wells
Campbell University
_______________________________________________
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

 
_______________________________________________
U2-Users mailing list
U2-Users@listserver.u2ug.org
http://listserver.u2ug.org/mailman/listinfo/u2-users

Reply via email to