[patch_done] Have problems with ZTable.Edit & Post
Posted: 27.03.2012, 20:20
I changed from 6.6.6 stable to 7.0.0 alpha with Delphi 7. Now I get the some errors like
SQL Error: Dynamic SQL Error SQL error code = -104 Unexpected end of command - line 1, column1. Error Code: -104. Invalid token.
I use Firebird 2.5.1. In 6.6.6 works this code.
Should I call such procedures like .Prepare? There are any Changes between 6.6.6 and 7.0.0?
Best Greetings
SQL Error: Dynamic SQL Error SQL error code = -104 Unexpected end of command - line 1, column1. Error Code: -104. Invalid token.
I use Firebird 2.5.1. In 6.6.6 works this code.
Code: Select all
procedure TForm1.Button2Click(Sender: TObject);
var
i: integer;
begin
self.ZTable1.Locate('ID', self.txtField.Text, [loCaseInsensitive]);
for i := 0 to self.ZTable1.RecordCount do
begin
if (self.ZTable1.State <> dsEdit) or
(self.ZTable1.State <> dsInsert) then
self.ZTable1.Edit;
if self.ZTable1.State = dsEdit then
begin
self.ZTable1STATUS.AsInteger := 1;
self.ZTable1ZEITSTEMPEL.AsString := '25.04.2012 17:45';
end;
self.ZTable1.Post;
self.ZTable1.Next;
end;
self.ZTable1.CommitUpdates;
end;
Best Greetings