Subject Cannot edit current row error
Author sdbeames
Hi all,
I need some help please. I'm using V4.2.Fn with BCB5.
One of my forms has a button handler that includes the following code.
The marked line causes a "Cannot Edit current Row" error! All the
other lines work fine when it's commented out!

JobsQry->Insert();
JobsQry->FieldByName("CLIENTNO")->AsInteger = nClientNo;
JobsQry->FieldByName("ACCNT_ID")->AsInteger = nAccntId;
JobsQry->FieldByName("PERCENTAGE")->AsInteger = nPercent; /<-******
JobsQry->FieldByName("AMOUNT")->AsFloat = fAmount;
JobsQry->FieldByName("REQUESTED")->AsDate = sRequested;
JobsQry->FieldByName("REQUIRED")->AsDate = sRequired;
JobsQry->FieldByName("DESCRIPTION")->AsString = sDescription;
JobsQry->Post();

The JOBS table has no triggers, and the definitions:
CREATE DOMAIN D_PERCENT AS SMALLINT;
PERCENTAGE D_PERCENT,

and JobsQry has SQL like:
SELECT J.JOBNO
, J.CLIENTNO
~SNIP~
, J.PERCENTAGE
~SNIP~
, J.DEPT
FROM JOBS J
JOIN ACCOUNTS A ON A.ACCNT_ID=J.ACCNT_ID
WHERE J.DEPT=USER

and an EditSQL like:
UPDATE JOBS SET
~SNIP~
CLIENTNO = :CLIENTNO,
ACCNT_ID = :ACCNT_ID,
PERCENTAGE = :PERCENTAGE,
~SNIP~
WHERE
JOBNO = :OLD_JOBNO

KeyLinks = JOBNO, (the PK)
ReadOnly is false,
No ColumnAttributes are set for PERCENTAGE,
Field Properties for JOBS.PERCENTAGE are Alignment:CENTER, Default
Value:100, Display Format:0%.

I'm running out of ideas.........any suggestions on where to look
next?
Thanks,
Steve