Vista Software
Tip: Buffered Records Explained

Buffered Records Explained

Applies to: Apollo VCL™

Many developers have asked why inserting, deleting and cancelling record changes in Apollo 3 acts differently under newer versions of Apollo. Here is the explanation.

Calling Insert or Append under Apollo 3.x actually added the record to the table at that moment. Issuing a Cancel following an Insert or Append would internally just call Delete to remove the record that it had already added.

This behavior was not correct. The current model, and also Apollo 4.x before it, this was corrected to properly buffer the new record addition and only if Post were called (or Commit) would an internal call to AppendBlank be made to add the new record to the table. Otherwise, if Cancel were called, the temporary record buffer is simply discarded.

Also, when inserting a new record, the record at the current cursor position is moved down and the new blank record is put in it's place until you Post. If you do an Insert with the cursor on a record in the middle of the grid display you will see this. If you are on the last record in the grid, the current (last) record is still moved down, but it is now out of view, as the new record has replaced it as the last position in the grid display.

In short, what you were seeing in Apollo 3.0 was a bug that was corrected in Apollo 4.x. Apollo VCL now conforms to standard TTable behavior, as it should.

Back
Apollo Database Engines