473,804 Members | 3,396 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Microsoft OLE DB Provider for ODBC Drivers

9 New Member
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
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 ',,,'','','','' )' at line 1
/save_inc.asp, line 47

I'm getting this error , when i use response.write( sql) instead of db_conn.execute (sql) it works fine .
for i=0 to (tSim_num)
LINE 47 :
sql = "insert into tach values (null,"&projID& ",'"&t_carr(i)& "','"&t_carType (i)&"','"&t_hos t(i)&"','"&t_di r(i)&"','"&t_pi n(i)&"','"&tSim _ip(i)&"',"&t_n um(i)&","&t_pc( i)&","&t_UID1(i )&","&t_UID2(i) &",'"&t_by(i)&" ','"&t_par(i)&" ','"&t_im(i)&"' ,'"&t_auto(i)&" ')"
db_conn.execute (sql)
next
Plz help
Mar 14 '07 #1
2 3004
jhardman
3,406 Recognized Expert Specialist
Microsoft OLE DB Provider for ODBC Drivers (0x80040E14)
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 ',,,'','','','' )' at line 1
/save_inc.asp, line 47

I'm getting this error , when i use response.write( sql) instead of db_conn.execute (sql) it works fine .
Expand|Select|Wrap|Line Numbers
  1. for i=0 to (tSim_num)
  2. LINE 47 : 
  3. sql = "insert into tach values (null,"&projID&",'"&t_carr(i)&"','"&t_carType(i)&"','"&t_host(i)&"','"&t_dir(i)&"','"&t_pin(i)&"','"&tSim_ip(i)&"',"&t_num(i)&","&t_pc(i)&","&t_UID1(i)&","&t_UID2(i)&",'"&t_by(i)&"','"&t_par(i)&"','"&t_im(i)&"','"&t_auto(i)&"')"
  4.     db_conn.execute(sql)
  5.     next
Plz help
It looks like you are passing a whole bunch of empty arguments to the insert line. There is a lot that can go wrong with any sql statement. I would suggest breaking down the insert line into shorter statements like the following. It may not solve the problem, but will likely give you a better idea of where the problem is:
Expand|Select|Wrap|Line Numbers
  1. Set objCon = Server.CreateObject("ADODB.Connection")
  2. objCon.Open "Provider=SQLOLEDB;DataSource=wwww;UID=xxx;Pwd=yyy;DataBase=zzzz;"
  3. set objRS = Server.CreateObject("ADODB.Recordset")
  4. objRS.open "SELECT * FROM [Book_files]", objCon, adOpenDynamic, adLockOptimistic
  5.  
  6. for i = 0 to tSim_num
  7.    objRS.addNew
  8.    objRS("projID") = projID
  9.    response.write "projID: " & projID & "<br>" & vbNewLine
  10.    objRS("comment") = null
  11.    response.write "comment: (null)<br>" & vbNewLine
  12.    objRS("carType") = carType(i)
  13.    response.write "carType: " & carType(i) & "<br>" & vbNewLine
  14.    'etc
  15.    objRS.update   
  16. next
  17.  
Like I said before, when you use just one line of code to insert, there is no telling where the problem arose, but this way should let you know where the problem is.

Let me know if this helps.

Jared
Mar 14 '07 #2
phantom3008
9 New Member
It looks like you are passing a whole bunch of empty arguments to the insert line. There is a lot that can go wrong with any sql statement. I would suggest breaking down the insert line into shorter statements like the following. It may not solve the problem, but will likely give you a better idea of where the problem is:
Expand|Select|Wrap|Line Numbers
  1. Set objCon = Server.CreateObject("ADODB.Connection")
  2. objCon.Open "Provider=SQLOLEDB;DataSource=wwww;UID=xxx;Pwd=yyy;DataBase=zzzz;"
  3. set objRS = Server.CreateObject("ADODB.Recordset")
  4. objRS.open "SELECT * FROM [Book_files]", objCon, adOpenDynamic, adLockOptimistic
  5.  
  6. for i = 0 to tSim_num
  7.    objRS.addNew
  8.    objRS("projID") = projID
  9.    response.write "projID: " & projID & "<br>" & vbNewLine
  10.    objRS("comment") = null
  11.    response.write "comment: (null)<br>" & vbNewLine
  12.    objRS("carType") = carType(i)
  13.    response.write "carType: " & carType(i) & "<br>" & vbNewLine
  14.    'etc
  15.    objRS.update   
  16. next
  17.  
Like I said before, when you use just one line of code to insert, there is no telling where the problem arose, but this way should let you know where the problem is.

Let me know if this helps.

Jared
the prob was in the loop coz it was adding an extra insert ...so instead i did
for i = 0 to (tSim-1) and now it works !! thanks a lot for ur time anyways ....
Mar 15 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

2
23781
by: paul tomlinson | last post by:
Hi folks - i've got a windows 2000 server (SP3) i've run the IIS lockdown tool on it and set for dynamic websites - all the static pages within the site work ok but an ASP section has been put in which now keeps giving me the error below : Microsoft OLE DB Provider for ODBC Drivers error '80004005' General error Unable to open registry key 'Temporary (volatile) Jet DSN for process 0x404 Thread 0x6ac DBC 0xbd7014 Jet'.
2
34239
by: Mark Sargent | last post by:
Hi All, what does the below error mean in plain English..? Cheers. Mark Sargent. Error Type: Microsoft OLE DB Provider for ODBC Drivers (0x80004005) General error Unable to open
7
13598
by: BrianS | last post by:
I am receiving this error anytime I attempt to connect to a MS access DSN. Not clue what happened to trigger this suddenly. Any help is greatly appreciated.
15
1377
by: M P | last post by:
What does this mean? I am accessing an ASP page that queries Access Database thru fileDSN. I'm using IIS 5.0 Win2K SP4 Microsoft OLE DB Provider for ODBC Drivers error '80004005' General error Unable to open registry key 'Temporary (volatile) Jet DSN for process 0x444 Thread 0xfe4 DBC 0x5200024 Jet'.
1
13747
by: Albert | last post by:
Hi guys, it's nice to join the forum. Can someone can help me? After 2 years of using a program, i suddenly got this error. I tried re-installing SQL but im still getting the message. Microsoft OLE DB Provider for ODBC Drivers error '80040e14' Cannot load the DLL xplog70.dll, or one of the DLLs it references. Reason: 193(error not found).
1
5783
by: Rajiv | last post by:
hi all , i m trying to coneect to a access database Using DSN dim rcon set rcon = server.CreateObject("ADODB.CONNECTION") rcon.mode = 1 ' adModeRead rcon.ConnectionString ="DSN=report" rCon.Open
4
2590
by: Saber | last post by:
In VS 2005 I made a setup project for my application. The application uses a mdb file and needs Microsoft Jet OLE DB Provider to run on another PCs. In Prerequisites section of Setup Property Pages there are some checkboxes including Microsoft Data Access Component 2.8. But in microsoft site they say: This release does not include Microsoft Jet, the Microsoft Jet OLE DB Provider or ODBC driver, the Desktop Database ODBC Drivers, or the...
2
8521
by: pericpero | last post by:
Hi There seem to be a number of posts already with this error message but none of them have helped me ... I am trying to execute some dynamic SQL from an ASP form to update or delete from a table and I get the following output:- == SQL=Update StockItemMaterials set =3 WHERE ="P0855" AND ="GOGGW" Microsoft OLE DB Provider for ODBC Drivers error '80040e10'
0
2737
by: Genken | last post by:
Please assist in this error i have provided the source code. Microsoft OLE DB Provider for ODBC Drivers (0x80040E10) Too few parameters. Expected 1. <% Set objconn = Server.CreateObject("ADODB.Connection") objconn.ConnectionString = "DRIVER=Microsoft Access Driver (*.mdb);DBQ=" & Server.MapPath('mypath") objconn.Open
2
5582
by: Rheal | last post by:
Hi Can someone help me. My error is : Microsoft OLE DB Provider for ODBC Drivers error '80040e07' Data type mismatch in criteria expression. /add.asp, line 73 my codes are <% dim DataCon, rsRec, strSql, strSql2, rsRec2 set DataCon = server.createobject("ADODB.Connection")
0
9705
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9575
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10320
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10073
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7609
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6846
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5645
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4288
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3806
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.