Programmieren - alles kontrollieren 4.934 Themen, 20.613 Beiträge

SQL problem mit format '\#dd/m/yyyy\#')

logo3 / 2 Antworten / Flachansicht Nickles

Hallo

ich bekomme eine fehlermedung wegen die struktur des datums.

kann mir jemand dies bitte lösen ?


Dim objDB As DAO.Database
Dim objRS As DAO.Recordset
Dim strSQL As String

strSQL = "INSERT INTO ALBARANES (" & _
"[sales unit], unit, [jvperson], [jzperson], name, " & _
"street, zipcode, city, city2, country, employee, " & _
"phone, deliverydate, subject, Text) " & _
"SELECT [sales unit], unit, [jvperson], [jzperson], " & _
"[name], [street], [zipcode], [city], [city2], " & _
"country, customer, [phone 1], " & _
Format(form_generar2.gei_fecha, '\#dd/m/yyyy\#') & ", " & _
"'" & Form_generar2.gei_asunto & "', " & _
"'" & Form_generar2.gei_texto & "' " & _
"FROM structureOK " & _
"WHERE ([unit]='18-000')"
Set objDB = CurrentDb
Set objRS = objDB.OpenRecordset(strSQL, , DAO.dbSQLPassThrough)
Call objRS.Close
Set objRS = Nothing
Set objDB = Nothing
----------------------------------------------

danke

logo3

bei Antwort benachrichtigen
Bergi2002 logo3 „SQL problem mit format '\#dd/m/yyyy\#')“
Optionen

Hi Logo,

normalerweise ist doch im Amerikanischen das Datum aufgebaut nach Monat / Tag / Jahr - vielleicht mal entsprechend anpassen? Müsste dann mm/dd/yyyy sein.

BG,

Bergi2002

Life* - *available for a limited time only. Limit one (1) per person. Subject to change without notice. Provided "as is" without any warranties. Nontransferable and is the sole responsibility of the recipient. May incur damages arising from use or misuse. Additional parts sold seperately. Your mileage may vary. Subject to all applicable fees and taxes. Terms and conditions apply. Other restrictions apply. (c) Cheezburger.com
bei Antwort benachrichtigen