Jump to content
Xtreme .Net Talk

Recommended Posts

Posted

I have the following SQL statement that I am trying to use within an asp page.

 

INSERT INTO RegDetails (user_name, password, name, email, make_of_car, model_of_car, year_of_manufacture, post_code, age, news_letter, user_type) VALUES ('lidds','dragnet','simon','simon@','toyota','supra','1997','rg29ab','17-25','Yes','private')

 

The SQL statement works fine when run out side of my asp page, the asp page code is:

 

Dim objConn
Set objConn = CreateObject("ADODB.Connection")

objConn.connectionstring="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\sites\Single7\mofomos\database\mofomos.mdb;User ID=;Password=;"
objConn.open

Dim strQ
 strQ = "INSERT INTO RegDetails (user_name, password, name, email, make_of_car, model_of_car, year_of_manufacture, post_code, age, news_letter, user_type) VALUES ('lidds','dragnet','simon','simon@','toyota','supra','1997','rg29ab','17-25','Yes','private')"
 objConn.Execute strQ
objConn.close

 

the following error is then produced:

 

Microsoft JET Database Engine error '80040e14'

Syntax error in INSERT INTO statement.

 

/html/regdetails_form_private_action.asp, line 92

 

 

Can anyone help as this driving me mad.

 

Cheers

 

Simon

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...