Is ventity predefined ?
I would simply place a set debug on and a trace to determine whch line is 
causing the problem.

Jim



----- Original Message ----
From: cdconrad <[email protected]>
To: RBASE-L Mailing List <[email protected]>
Sent: Tuesday, October 6, 2009 2:23:54 AM
Subject: [RBASE-L] - EEP - Append Command

I am using an eep to check if the company number is different than the
control number. If so I want the eep to append command to add rows to the
table.  However I get a error on the form.

Here is the code



  --PROGRAM TITLE - addrow.eep

  --last updated 06/10/2009

  DROP CURSOR cur1

  DECLARE cur1 CURSOR FOR SELECT cocode FROM gl_genled +

      WHERE refno = .vrefno

  OPEN cur1

  FETCH cur1 INTO vcompcode ind_v1

  WHILE SQLCODE = 0 THEN

      IF vcompcode <> .ventity THEN

            APPEND gl_genled TO gl_genled WHERE CURRENT OF cur1

            UPDATE gl_genled SET acctno = 111000900 +

              WHERE COUNT = LAST AND amtdr > 0

            APPEND gl_genled TO gl_genled WHERE CURRENT OF cur1

            UPDATE gl_genled SET acctno = 111000900 WHERE COUNT = LAST

      ENDIF

      FETCH cur1 INTO vcompcode ind_v1

  ENDWHILE

  CLOSE cur1

  DROP CURSOR cur1

  RETURN



Any suggestions

Chuck Conrad





Reply via email to