N
Noozer
I have an ASP page that is trying to add a record to an MS Access database,
but I'm getting a MS Jet error 80040e14. Syntax error in INSERT INTO
statement.
The INSERT command I'm using is:
INSERT INTO Calls (Who, When) VALUES ('10.0.94.11', #1/18/2005 9:56:37
AM#)
...where "Who" is a 16 character text field and When is a General format
Date/Time field. The only other field in the Calls table is "CallID" with is
an autonumber.
Code I'm using is:
'Create database objects
set adoCon = server.CreateObject("ADODB.Connection")
set rsSet = server.CreateObject("ADODB.Recordset")
'Connect to database
adoCon.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" &
Server.MapPath("Calls.mdb")
'Add Call to database
strSQL="INSERT INTO Calls (Who, When) VALUES ('" & AgentIP & "', #" & When
& "#);"
rsSet.open strSQL, adoCon
....any idea's why this is happening? I believe it has something to do with
the date, but I can't figure it out.
Thx!
but I'm getting a MS Jet error 80040e14. Syntax error in INSERT INTO
statement.
The INSERT command I'm using is:
INSERT INTO Calls (Who, When) VALUES ('10.0.94.11', #1/18/2005 9:56:37
AM#)
...where "Who" is a 16 character text field and When is a General format
Date/Time field. The only other field in the Calls table is "CallID" with is
an autonumber.
Code I'm using is:
'Create database objects
set adoCon = server.CreateObject("ADODB.Connection")
set rsSet = server.CreateObject("ADODB.Recordset")
'Connect to database
adoCon.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" &
Server.MapPath("Calls.mdb")
'Add Call to database
strSQL="INSERT INTO Calls (Who, When) VALUES ('" & AgentIP & "', #" & When
& "#);"
rsSet.open strSQL, adoCon
....any idea's why this is happening? I believe it has something to do with
the date, but I can't figure it out.
Thx!