Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

ASP Error - Microsoft OLE DB Provider for SQL Server error '80040e14'

Posted on 2009-05-10
4
Medium Priority
?
1,038 Views
Last Modified: 2012-06-27
Hi,

I get this error message on my ASP web page.  

Any ideas
Cheers Geoff

Microsoft OLE DB Provider for SQL Server error '80040e14'

Incorrect syntax near 'index'. If this is intended as a part of a table hint, A WITH keyword and parenthesis are now required. See SQL Server Books Online for proper syntax.

/index.asp, line 13




<!--#include file="Connections/dboMTT_cs.asp" -->
<%
Dim rsIndex
Dim rsIndex_cmd
Dim rsIndex_numRows
 
Set rsIndex_cmd = Server.CreateObject ("ADODB.Command")
rsIndex_cmd.ActiveConnection = MM_dboMTT_cs_STRING
rsIndex_cmd.CommandText = "SELECT heading, [date], contentmain, photocaption, photocredit, photolink, readmore FROM dbo.index" 
rsIndex_cmd.Prepared = true
 
Set rsIndex = rsIndex_cmd.Execute (line 13)
rsIndex_numRows = 0
%>

Open in new window

0
Comment
Question by:jedtheguru
  • 2
  • 2
4 Comments
 
LVL 12

Expert Comment

by:geowrian
ID: 24347639
Line 12 has the text "(Line 13)" in it...is that a copy/paste error or the source code?

Line 12 should say:
Set rsIndex = rsIndex_cmd.Execute
0
 

Author Comment

by:jedtheguru
ID: 24347652
Hi,

I have added this to indicate that this is line 13.  this is not in my code

Cheers Geoff
0
 
LVL 12

Accepted Solution

by:
geowrian earned 750 total points
ID: 24347666
Thanks. I was hoping it was something simple like that.

Another possibly-simple thing: isn't "index" in "dbo.index" a reserved word? What if you put brackets around it?
0
 

Author Closing Comment

by:jedtheguru
ID: 31579890
Thanks for that, I was being dumb.
Yes index was a reserved word
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Loops Section Overview
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …

877 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question