Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Wols Lists
On 08/02/13 07:30, Tony Gravagno wrote: I think people understand exactly what you're saying, but disagree. Most applications don't use the more rigorous coding for having a Locked clause that provides additional information to the user, retries, etc. That's not wrong, it's just not necessary

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Wjhonson
We don't really have the luxury to rewrite the entire system. But we can fix one program a day -Original Message- From: Wols Lists antli...@youngman.org.uk To: u2-users u2-users@listserver.u2ug.org Sent: Fri, Feb 8, 2013 1:22 am Subject: Re: [U2] Record locks (Unidata 7.2)

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Jon Wells
I should add that (in our test account) I switched to the READU statement along with a LOCKED clause -   READU STU.REC FROM STU.FILE, STU.ID LOCKED     CRT STU.ID: RECORD IS LOCKED   END THEN     STU.REC48 = INST.CRED     STU.REC49 = INET.CRED     WRITE STU.REC ON STU.FILE, STU.ID   END  I

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Wjhonson
Jon the LOCKED clause acts like a Then...else You can only take one branch. So for the locked record, it took the LOCKED branch and ignored the END THEN branch Because the Locked clause is another case you see? Like Readu CASE Locked: do this CASE NotLockedANd Exists: do that CASE

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Lunt, Bruce
One technique that I have used, in the past, has been to save a list of locked ID's and at the end of the program re-try them when all else has finished. Then if they are still locked the program will send a message to me or the operator to alert that there is a locked record. -Original

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Woodward, Bob
You should have written it something like this: TRY.AGAIN: READU STU.REC FROM STU.FILE, STU.ID LOCKED CRT STU.ID: RECORD IS LOCKED SLEEP 2 GOTO TRY.AGAIN END THEN STU.REC48 = INST.CRED STU.REC49 = INET.CRED WRITE STU.REC ON STU.FILE, STU.ID END You have to add the

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Israel, John R.
I would also add some type of bailout logic in case the record NEVER frees up (user went home for the weekend). Obviously, you need to make the call on this on a case by case situation, but you would not want a critical process (like month end) to fail because Joe Blow left a record locked.

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Mecki Foerthmann
Oh no, you don't have to add a label and you don't have to use GOTO. TRY_AGAIN = 1 LOOP WHILE TRY_AGAIN READU STU.REC FROM STU.FILE, STU.ID LOCKED CRT STU.ID: RECORD IS LOCKED SLEEP 2 END THEN STU.REC48 = INST.CRED STU.REC49 = INET.CRED WRITE STU.REC ON STU.FILE, STU.ID

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread Mecki Foerthmann
On second thought this won't do either since it hasn't got an ELSE clause. ERR = '' LOOP TRY_AGAIN = 0 READU STU.REC FROM STU.FILE, STU.ID LOCKED CRT STU.ID: RECORD IS LOCKED - (Q)uit or Enter INPUT REPLY: IF REPLY # 'Q' THEN TRY_AGAIN = 1 ELSE ABORT END ELSE STU.REC = '' UNTIL

Re: [U2] Record locks (Unidata 7.2)

2013-02-08 Thread John Hester
I agree, though I find the LOCKED clause is needed more often than not in our particular environment. I've always used the following logic to determine which course of action to take. In this example: READU REC FROM FILE, ID THEN [do something] END ELSE [do something else] END [operate on

[U2] UniData 64 bit sanity check

2013-02-08 Thread Jeff Fitzgerald
Hi all, Just want to get confirmation or a slap upside the head It looks to me like all the UDT Windows versions are 32 bit and that there isn't a 64 bit version - true? Thanks! Jeff Fitzgerald Fitzgerald Long, Inc. www.fitzlong.com ___

Re: [U2] UniData 64 bit sanity check

2013-02-08 Thread Jeffrey Butera
Last check there are no 64 bit builds for intel (win/Linux) Jeff Butera -- A tree falls the way it leans. Be careful which way you lean. The Lorax On Feb 8, 2013, at 9:57 PM, Jeff Fitzgerald j...@fitzlong.com wrote: Hi all, Just want to get confirmation or a slap upside the head It

Re: [U2] UniData 64 bit sanity check

2013-02-08 Thread Daniel McGrath
Correct. We are working on them. Regards, Dan From: u2-users-boun...@listserver.u2ug.org [u2-users-boun...@listserver.u2ug.org] on behalf of Jeff Fitzgerald [j...@fitzlong.com] Sent: Friday, 8 February 2013 7:57 PM To: U2-Users@listserver.u2ug.org