Einzelnen Beitrag anzeigen

Angel4585

Registriert seit: 4. Okt 2005
Ort: i.d.N.v. Freiburg im Breisgau
2.199 Beiträge
 
Delphi 2010 Professional
 
#1

Zeos:Unterschiedliche Typen für Feld;erwartet: String, gefunden: WideString

  Alt 7. Mär 2013, 11:17
Datenbank: MySQL • Version: 5.0.51b • Zugriff über: ZEOS 7.0.3
Guten Tag!

Icc habe die gleiche Fehlermeldung wie in diesem Thread beschrieben: http://www.delphipraxis.net/47101-mi...zugreifen.html

Da ich vermutlich mit einer neueren Version von ZEOS arbeite, frage ich mich woran das jetzt genau liegt, da der dort angegebene Link zur Fehlermeldung nicht mehr funktioniert.

Ich habe gerade versucht älteres Programm welches mit einer alten Verison von ZEOS und Delphi 2005 compiliert wurde unter Delphi 2010 mit ZEOS 7.0.3 zum Laufen zu bringen. Und stoße auf die Meldung:

tqServiceOptions: Unterschiedliche Typen für Feld 'Betreff'; erwartet: String, gefunden: WideString

tqServiceOptions ist der name der TZQuery
Betreff ist ein TStringField mit 80 Zeichen.

In der Datenbank ist Betreff ein VarChar mit 80 Zeichen.
Die Datenbanktabelle ist InnoDB.

Der Fehler selbst kommt beim Open-Befehl.
Der SQL-Befehl ist schlicht "select * from Tabellenname".
Hat jemand eine Idee woran das liegen könnte?
Hier noch mehr Details zur Meldung:

Zitat:
[5067E817]{dbrtl140.bpl} DB.DatabaseError (Line 2884, "DB.pas" + 2) + $36
[5067E8A1]{dbrtl140.bpl} DB.DatabaseErrorFmt (Line 2891, "DB.pas" + 1) + $15
[149EB34D]{ZComponent140.bpl} Zabstractrodataset.TZAbstractRODataset.CheckFieldC ompatibility + $99
[506917E6]{dbrtl140.bpl} DB.DoBindFields (Line 11629, "DB.pas" + 26) + $17
[506918E1]{dbrtl140.bpl} DB.TDataSet.BindFields (Line 11654, "DB.pas" + 4) + $7
[149E8AB6]{ZComponent140.bpl} Zabstractrodataset.TZAbstractRODataset.InternalOpe n + $256
[50690D05]{dbrtl140.bpl} DB.TDataSet.DoInternalOpen (Line 11328, "DB.pas" + 2) + $4
[50690DBE]{dbrtl140.bpl} DB.TDataSet.OpenCursor (Line 11357, "DB.pas" + 4) + $2
[50690C79]{dbrtl140.bpl} DB.TDataSet.SetActive (Line 11310, "DB.pas" + 12) + $7
[500516EE]{rtl140.bpl } TypInfo.SetOrdProp (Line 1723, "TypInfo.pas" + 27) + $0
[20DA5FF2]{designide140.bpl} DesignEditors.TPropertyEditor.SetOrdValue (Line 841, "DesignEditors.pas" + 2) + $E
[20DEB0FD]{designide140.bpl} VCLEditors.TBooleanProperty.MouseUp (Line 1838, "VCLEditors.pas" + 5) + $10
[20EBFF05]{vclide140.bpl} PropBox.TCustomPropListBox.ItemMouseUp (Line 1625, "propbox.pas" + 16) + $1B
[20EC00FB]{vclide140.bpl} PropBox.TCustomPropListBox.MouseUp (Line 1690, "propbox.pas" + 1) + $D
[50296810]{vcl140.bpl } Controls.TControl.DoMouseUp (Line 7306, "Controls.pas" + 2) + $28
[5029688C]{vcl140.bpl } Controls.TControl.WMLButtonUp (Line 7319, "Controls.pas" + 9) + $6
[20EC5740]{vclide140.bpl} IDEInspListBox.TInspListBox.WMLButtonUp (Line 1615, "IDEInspListBox.pas" + 3) + $4
[50295E70]{vcl140.bpl } Controls.TControl.WndProc (Line 7062, "Controls.pas" + 91) + $6
[50299FCB]{vcl140.bpl } Controls.TWinControl.IsControlMouseMsg (Line 9596, "Controls.pas" + 1) + $9
[5029098A]{vcl140.bpl } Controls.FindControl (Line 3377, "Controls.pas" + 6) + $9
[5029A738]{vcl140.bpl } Controls.TWinControl.WndProc (Line 9819, "Controls.pas" + 144) + $6
[501F06D4]{vcl140.bpl } StdCtrls.TCustomListBox.WndProc (Line 6117, "StdCtrls.pas" + 37) + $4
[50299DD8]{vcl140.bpl } Controls.TWinControl.MainWndProc (Line 9540, "Controls.pas" + 3) + $6
[50076408]{rtl140.bpl } Classes.StdWndProc (Line 13015, "Classes.pas" + 8) + $0
[502C9921]{vcl140.bpl } Forms.TApplication.StopHintTimer (Line 10491, "Forms.pas" + 3) + $6
[502C8775]{vcl140.bpl } Forms.TApplication.ProcessMessage (Line 9760, "Forms.pas" + 30) + $1
[502C87BA]{vcl140.bpl } Forms.TApplication.HandleMessage (Line 9790, "Forms.pas" + 1) + $4
[502C8AE5]{vcl140.bpl } Forms.TApplication.Run (Line 9927, "Forms.pas" + 26) + $3
[004369AE]{bds.exe } bds.bds (Line 200, "" + 8) + $FFFB
Wenn ich die betroffenen Felder (alle String-Felder) neu mache als TWideStringField anstatt TStringField, dann klappt es.
Aber das möchte ich natürlich nicht für die ganzen Felder. Wo/was muss ich ändern, damit ich die Felder der Tables und Queries nicht ändern muss?
Martin Weber
Ich bin ein Rüsselmops

Geändert von Angel4585 ( 7. Mär 2013 um 11:30 Uhr)
  Mit Zitat antworten Zitat