Einzelnen Beitrag anzeigen

akio87

Registriert seit: 18. Mär 2010
44 Beiträge
 
Delphi XE8 Architect
 
#1

Syntax SQL Update

  Alt 30. Jun 2015, 23:09
Datenbank: MySQL • Version: 5 • Zugriff über: Ka
Hallo,

ich habe aktuell ein SQL Query Update Syntax problem...

ich habe bereits schon viele Schreibweisen ausprobiert und jedesmal kommt eine Fehlermeldung an unterschiedlicher stelle, wie angehängt.

Ich hatte schon alle Edits in QuotedStr() gepackt, schon "" weggelassen und [""] ausprobiert, aber nichts hilft...

Habt Ihr eine schnelle abhilfe für mich?

Aktuell:

Code:
  MainModule.UniMainModule.mySQLQuery1.SQL.Text :=         'update `' + UniMainModule.SQLTabelle + '`' + #10 +
                                                            'set' + #10 +
                                                            ' Vorname = "'+UniEdit8.Text+'",'+ #10 +
                                                            ' Name = "'+UniEdit12.Text+'",'+ #10 +
                                                            ' user = "'+lowercase(UniEdit13.Text)+'",'+ #10 +
                                                            ' Firma = "'+UniEdit1.Text+'",'+ #10 +
                                                            ' Adress1 = "'+UniEdit2.Text+'",'+ #10 +
                                                            ' Adress2 = "'+UniEdit3.Text+'",'+ #10 +
                                                            ' Straße = "'+UniEdit4.Text+'",'+ #10 +
                                                            ' PLZ = "'+ UniEdit5.Text+'",'+ #10 +
                                                            ' Ort = "'+ UniEdit6.Text+'",'+ #10 +
                                                            ' Land = "'+ UniEdit7.Text+'",'+ #10 +
                                                            ' Telefonnummer = '+ UniEdit14.Text + '' + #10 +
                                                            'where'+ #10 +
                                                            ' Vorname = '+UniMainModule.Vorname+' and'+ #10 +
                                                            ' Name = '+UniMainModule.Name+' and'+ #10 +
                                                            ' user = '+UniMainModule.user+' and'+ #10 +
                                                            ' Firma = '+UniMainModule.Firma+' and'+ #10 +
                                                            ' Adress1 = '+UniMainModule.Adress1+' and'+ #10 +
                                                            ' Adress2 = '+UniMainModule.Adress2+' and'+ #10 +
                                                            ' Straße = '+UniMainModule.Straße+' and'+ #10 +
                                                            ' PLZ = '+UniMainModule.PLZ+' and'+ #10 +
                                                            ' Ort = '+UniMainModule.Ort+' and'+ #10 +
                                                            ' Land = '+UniMainModule.Land+' and'+ #10 +
                                                            ' Telefonnummer = ' + UniMainModule.Telefon + ';';

  MainModule.UniMainModule.mySQLQuery1.ExecSQL;
Miniaturansicht angehängter Grafiken
dfa281-1435703033.png  

Geändert von TBx ( 1. Jul 2015 um 08:12 Uhr) Grund: Fehlermeldung hinzugefügt
  Mit Zitat antworten Zitat