Database Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsDatabasesDatabase Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old February 18th, 2010, 12:01 PM
mankind mankind is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2010
Posts: 1 mankind User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 8 m 12 sec
Reputation Power: 0
INSERT data into MySQL database using ASP

Hi,

I am trying to insert new data into a MySQL database using ASP, through a CMS system we have on the website, but the command keeps erroring. The code I am using is:

sql = "INSERT INTO tgCaseStudies (Title, Desc, Client, Details, Duration, Value, TypeID, Active, Secured) values ("& title &","& desc &","& client &","& details &","& duration &","& ivalue &","& itype &",1,"& secured &")"
con.execute = sql

The above code gives the error message of:

Microsoft OLE DB Provider for ODBC Drivers error '80040e14'

[MySQL][ODBC 5.1 Driver][mysqld-5.1.37-community]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'Desc, Client, Details, Duration, Value, TypeID, Active, Secured) values (gvdqjvx' at line 1

/admin/includes/functions_newcasescript.asp, line 43

when the script is run.

Can anyone help as I've tried everything I can think of to make this work. I think the syntax variables are wrong, but I aren't sure. I am using MySQL v 5.1. Does the above code need upgrading some how to make it work, as it has come from an old version of ASP?

The reference to line 43 in the error message contains:

con.execute = sql

Any help would be appreciated. I've spent days trying to figure it out.

Many thanks.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsDatabasesDatabase Development > INSERT data into MySQL database using ASP


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap