FIRST_RECORD not working
From: P.Smith <smithpd_at_timken.com>
Date: 22 Apr 2004 11:26:52 -0700
Message-ID: <c30bedf8.0404221026.773fcb24_at_posting.google.com>
I have a form with check boxes beside each record. I then have a button to push and the checked records are to be moved from one table to another, and deleted from the first table. My 'WHEN BUTTON PRESSED' code is below. It is not going through my While loop of while :System.last_record <> true. I have added the message statements to confirm that it is not going through the WHILE loop at all and it does print the 'FIRST IF BLOCK' message, then the AFTER LOOP message. Any reasonable suggestions will be appreciated.
GO_BLOCK('BM');
END; Received on Thu Apr 22 2004 - 20:26:52 CEST
Date: 22 Apr 2004 11:26:52 -0700
Message-ID: <c30bedf8.0404221026.773fcb24_at_posting.google.com>
I have a form with check boxes beside each record. I then have a button to push and the checked records are to be moved from one table to another, and deleted from the first table. My 'WHEN BUTTON PRESSED' code is below. It is not going through my While loop of while :System.last_record <> true. I have added the message statements to confirm that it is not going through the WHILE loop at all and it does print the 'FIRST IF BLOCK' message, then the AFTER LOOP message. Any reasonable suggestions will be appreciated.
BEGIN
FIRST_RECORD; IF :SYSTEM.LAST_RECORD = 'TRUE' THEN FIRST_RECORD; MESSAGE('INSIDE FIRST IF BLOCK '||:BS.OP_CHK,ACKNOWLEDGE); END IF; MESSAGE('INSIDE BEGIN BLOCK', ACKNOWLEDGE); WHILE (:SYSTEM.LAST_RECORD != 'TRUE') LOOP MESSAGE('INSIDE WHILE LOOP '||:BS.OP_CHK,ACKNOWLEDGE); IF :bs.OP_CHK = 'Y' THEN l_MOVE_needed := TRUE; MESSAGE('INSIDE IF BLOCK', ACKNOWLEDGE); INSERT INTO ...; DELETE FROM ...; END IF; NEXT_RECORD; END LOOP; MESSAGE('AFTER LOOP',ACKNOWLEDGE);
GO_BLOCK('BM');
END; Received on Thu Apr 22 2004 - 20:26:52 CEST