Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2010-01-04 Thread Buss, Troy (Logitek Systems)
Thanks Stuart. Yep, it is part of a terminal escape sequence and I actually wrote a subroutine that I called when this occurred that scanned all of common for the escape sequence. I only found subsets of the string, and not the full string that was being inserted into CITEM when the read failed.

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-25 Thread Kathleene M Hunter
Need to use the LOCK conditional on the READU. ELSE is if the record does not exist. Do a help on READU to get more details. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Mecki Foerthmann Sent: Wednesday, December

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-23 Thread Mecki Foerthmann
Hi Firstly READU will not execute the ELSE clause when the item is locked. It will just sit there and wait for the lock to be released. Regardless if it is a bug or not, your piece of code just doesn't make sense. What do you actually try to achieve? You try to read a record and when it doesn't

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-23 Thread Buss, Troy (Logitek Systems)
Mecki, Thanks for your ideas and help. Correct, the READU will stop on a record locked condition which is not the problem. Also this is not my code, but represents maybe 2000 read statements that might be in the entire application that assumes that the CITEM will not be changed if the ELSE

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-23 Thread Curt Stewart
Troy, The things that stick out to me about this, is that CITEM is a common, it has changed values and it hasn't been reproduced outside of the 4gl code. I would look into the common statements of the code surrounding and including the code that you have isolated this problem to and verify

[U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-22 Thread Buss, Troy (Logitek Systems)
We are running universe 10.2.10 in pick flavor. I have a program (part of a 4gl subroutine) that simplified does the following: CITEM = READU CITEM FROM F.FILE, CID THEN END ELSE IF CITEM # THEN PRINT CITEM IS NOT NULL! END According to the documentation, when running in pick

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-22 Thread George Gallen
Does it happen if it's a named common? If it doesn't, then can you make all your unnamed commons - /noname/ ? -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users- boun...@listserver.u2ug.org] On Behalf Of Buss, Troy (Logitek Systems) Sent: Tuesday, December

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-22 Thread David Jordan
Hi Troy The problem with that code is that the else clause is taken when the record is locked. You are assuming if the else clause is taken that the record does not exist, which is not a safe assumption. I would suggest Readu citem from fv, key locked * locked options End then * then options

Re: [U2] [UV] odd problem with read statement assigning variable with random data with else clause in pick flavor

2009-12-22 Thread Buss, Troy (Logitek Systems)
Thanks for the replies... In this example I was using, the ID was not on file, so it would not have taken the LOCKED clause. I just added the locked clause to my actual failing code to test the theory and it still takes the ELSE clause because the record is truly not on file. I tried George's