Safwan
2006-08-03 19:31:59 UTC
Hi
BDS2006:BCB
IB7.5 SP1
Create Table A (A Integer Not Null Primary Key);
Create Table B (B Integer);
Insert Into B (B) Values (1);
Commit;
Create Trigger A_AI FOR A
Active After Insert
As
Begin
Update B Set B = B + New.A;
End;
That's in the Database.
IBDataSet1->Insert ();
IBDataSet1B->AsInteger = 1000;
IBDataSet1->Post ();
....
IBDataSet1->Edit ();
IBDataSet1B->AsInteger = 500;
IBDataSet1->Post ();
IBTransaction1->Commit ();
I suppose to got the value 501 in the table A; but I got 1001.
Does the trigger get the first value inserted and ignore any changing of the
value later on.
Thanks.
BDS2006:BCB
IB7.5 SP1
Create Table A (A Integer Not Null Primary Key);
Create Table B (B Integer);
Insert Into B (B) Values (1);
Commit;
Create Trigger A_AI FOR A
Active After Insert
As
Begin
Update B Set B = B + New.A;
End;
That's in the Database.
IBDataSet1->Insert ();
IBDataSet1B->AsInteger = 1000;
IBDataSet1->Post ();
....
IBDataSet1->Edit ();
IBDataSet1B->AsInteger = 500;
IBDataSet1->Post ();
IBTransaction1->Commit ();
I suppose to got the value 501 in the table A; but I got 1001.
Does the trigger get the first value inserted and ignore any changing of the
value later on.
Thanks.