Hallo,
folgende SQL Abfrage funktioniert nur nach Programmstart.
Erneute Abfrage ergibt immer wieder gleiches Ergebnis obwohl sich
DB Inhalt geändert hat.
Wo könnte der Fehler liegen ?
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33:
| procedure TForm1.FormCreate(Sender: TObject); begin Form1.ZConnection1.Database := 'Pfad zur Datenbank'; Form1.ZConnection1.HostName := 'IP des Rechners'; Form1.ZConnection1.Password := 'masterkey'; Form1.ZConnection1.Protocol := 'firebird-1.5'; Form1.ZConnection1.User := 'SYSDBA'; Form1.ZConnection1.ReadOnly := false; Form1.ZConnection1.SQLHourGlass := true; Form1.ZConnection1.Properties.Add('lc_ctype=ISO8859_1'); Form1.ZConnection1.Properties.Add('Dialect=3'); Form1.ZConnection1.Connected := true; end;
procedure TForm1.Button1Click(Sender: TObject); var SQLStrg, MDS_Kenn : String; begin SQLStrg := 'SELECT * FROM "CAM00"'; ZReadOnlyQuery1.Connection := ZConnection1; ZReadOnlyQuery1.Close; ZReadOnlyQuery1.SQL.Clear; ZReadOnlyQuery1.SQL.Add(SQLStrg); ZReadOnlyQuery1.ExecSQL; ZReadOnlyQuery1.Open; ZReadOnlyQuery1.First; while (not ZReadOnlyQuery1.Eof) do begin end; ZReadOnlyQuery1.Active := false; end; |
Vielen Dank im Voraus.
Gruß Marienberger