SQLDB, tfield.oldvalue shows value from current row not activerecord, bug? lazarus / 63-Database ---------------------------------------------------------------------- Soner · 2018-12-10 12:28 I am using TDataset.ActiveRecord property. When one field is not changed, then field.oldvalue shows the value from current row not from active record. Only when the field value changed then it show right value. Is this bug? Look at my comments on screenshots. (I had similar error on zeoscomponents. http://zeoslib.sourceforge.net/viewtopic.php?f=28&t=84847 ) ---------------------------------------------------------------------- Soner · 2018-12-10 12:29 this is example project: ---------------------------------------------------------------------- Soner · 2018-12-12 08:46 Is nobody using tfield.olvalue, tdataset.activerecord in his programs? ---------------------------------------------------------------------- Soner · 2018-12-12 13:19 Yes it is bug, It should show correct value or nothing.I reported it here https://bugs.freepascal.org/view.php?id=34694 (PS: In example from above save-button does not work. It is half ported zeos example.) ---------------------------------------------------------------------- valdir.marcos · 2019-02-22 22:08 Quote from: Soner on December 10, 2018, 01:28:37 pmI am using TDataset.ActiveRecord property. When one field is not changed, then field.oldvalue shows the value from current row not from active record. Only when the field value changed then it show right value. Is this bug? Look at my comments on screenshots. (I had similar error on zeoscomponents. http://zeoslib.sourceforge.net/viewtopic.php?f=28&t=84847 )I don't use TDataset.ActiveRecord, but a similar approach related to OldValue x NewValue could be: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i procedure TForm1.FormCreate(Sender: TObject);begin  IBConnection1.Connected := False;  IBConnection1.HostName := 'your server/3050';  IBConnection1.DatabaseName := 'your database';  IBConnection1.UserName := 'your user';  IBConnection1.Password := 'your password';  IBConnection1.CharSet := 'UTF8';  IBConnection1.Connected := True;   SQLQuery1.Close;  SQLQuery1.SQL.Text := 'Select Field2 From Table1 Where Field1 = 1;';  SQLQuery1.Open;  SQLQuery1.Edit;  SQLQuery1.FieldByName('Field2').AsString := 'new value';  ShowMessage('OldValue: ' + SQLQuery1.FieldByName('Field2').OldValue + LineEnding +              'NewValue: ' + SQLQuery1.FieldByName('Field2').NewValue);  SQLQuery1.CancelUpdates;  SQLQuery1.Cancel;  SQLTransaction1.Rollback ;  IBConnection1.Connected := False;end; ---------------------------------------------------------------------- Soner · 2019-03-01 17:51 Thanks for your effort, but I need it without changing Cursor position (TDBGrid).