Using flamerobin, success.
sorry my bad english.
Code: Select all
SELECT RDB$SET_CONTEXT('USER_TRANSACTION', 'DOC_ID', 8) FROM RDB$DATABASE;
UPDATE "mstItem" SET "ItemDeptID"= COALESCE(CAST(RDB$GET_CONTEXT('USER_TRANSACTION', 'DOC_ID') AS INTEGER),0) + ID WHERE ID=1;
UPDATE "mstItem" SET "ItemDeptID"= COALESCE(CAST(RDB$GET_CONTEXT('USER_TRANSACTION', 'DOC_ID') AS INTEGER),0) + ID WHERE ID=2;