Solved

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

Posted on 2006-07-13
5
605 Views
Last Modified: 2007-12-19
I have a webpage that accepts some info and feeds it to a table in a SQL server 2005 database. This works fine on SQL server 2000. But it gives me following error when I accept all the info -

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

[Microsoft][SQL Native Client][SQL Server]Inserts, updates & deletes are not permitted from Internet Information

C:\WEB\HELP_DESK\../ado/ado_start.inc, line 7

This is the ado_start.inc code -

<%'SET UP ACTIVEX DATA OBJECT
set my_conn = server.createobject("adodb.connection")
set my_rows = server.createobject("adodb.recordset")
my_conn.open "Driver={SQL Native Client};Server=mmdckvm4;Database=work_force;UID=mab_help_desk;PWD=thepike;"
my_rows.open sql, my_conn
app = "" %>
0
Comment
Question by:ariesmeeta
  • 3
  • 2
5 Comments
 
LVL 7

Accepted Solution

by:
assyst earned 500 total points
ID: 17099714
Change the connection string as below and try

my_conn.open "Provider=SQLNCLI;Server=mmdckvm4;Database=work_force;UID=mab_help_desk;PWD=thepike;"

Good Luck

0
 

Author Comment

by:ariesmeeta
ID: 17099737
hi assyst:
then i get the following error -

ADODB.Recordset error '800a0cc1'

Item cannot be found in the collection corresponding to the requested name or ordinal.

/help_desk/help_desk_insert.inc, line 19
0
 

Author Comment

by:ariesmeeta
ID: 17099817
This is the help_desk_insert.inc

<%
'SET POINTER TO HOURGLASS
mousepointer = 11

'BYPASS INSERT AND UPDATE(S)  ??
disp = 0
if disp = 0 then

'INSERT STARTS HERE
app = app1
sql = "help_desk_insert " & null_q(badge) & "," & null_q(category) & ","
sql = sql & null_q(node_name) & "," & null_q(some_user)

%>
<!--#include file="../ado/ado_start.inc" -->
<%

'GET support.ref OF NEWLY INSERTED ROW TO UPDATE REMAINING FIELDS
ref=my_rows(0)

%>

<!--#include file="../ado/ado_end.inc" -->

<!-- BEGIN: STUFF THAT USED TO BE IN "help_desk_description.inc" -->

<%

'PREPARE TO UPDATE BIG AND OTHER COLUMNS
app = app1
sql =      "select description, description2, description3, description4, " & _
      "profile_problem, inventory_problem, user_comment, ces_beep, subject, status " & _
      "from support where ref = " & ref
%>

<!--#include file="../ado/ado_start_update.inc" -->

<%

'SET THE DESCRIPTION FIELDS FOR THE UPDATE
my_rows(0) = mid(description,1,255)
my_rows(1) = mid(description,256,255)
my_rows(2) = mid(description,511,255)
'my_rows(3) = mid(description,766,255)
my_rows(3) = contactemail

'SET ADDITIONAL FIELDS FOR THE UPDATE (02/10/2000 DPH)
if len(trim(profile_problem)) > 0 then
      my_rows(4) = profile_problem
end if
if len(trim(inventory_problem)) > 0 then
      my_rows(5) = inventory_problem
end if
if len(trim(user_comment)) > 0 then
      my_rows(6) = user_comment
end if
if beeper = "on" or beeper = "1" then
      my_rows(7) = "1"
end if

'SET SUBJECT AND STATUS
my_rows(8) = subject
my_rows(9) = "1"

'DO THE UPDATE
my_rows.update

%>

<!--#include file="../ado/ado_end.inc" -->

<!-- END: STUFF THAT USED TO BE IN "help_desk_description.inc" -->

<%

'SET MOUSE BACK TO NORMAL
end if

mousepointer = 0

%>
0
 
LVL 7

Expert Comment

by:assyst
ID: 17099939
Hi,

>>>ADODB.Recordset error '800a0cc1'

>>>Item cannot be found in the collection corresponding to the requested name or ordinal.

This error is not related to the connection.
The connection is a success now..

Check the Code and find out whether a colun name not in the select statement is used..

i suspect
"my_rows(3) = contactemail"
which is not there in the select query

This error is coming because you are using a invalid column in your code..

Pls check

Good Luck
0
 

Author Comment

by:ariesmeeta
ID: 17103011
hi Assyst
Thanks for the first solution. I have accepted it. I will open second question for this to continue. In the meantime, I ran the SQL profiler. This code runs perfectly on SQL 2000 but it gives me this error now in 2005.  I will post detailed and new question by end of the day.
Thanks,
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Join & Write a Comment

Database tuning – How to start and what to tune. This question is frequently asked by many people, both online and offline. There is no hard and fast rule-of-thumb for performance tuning, however, before beginning the tuning process one should a…
Read about achieving the basic levels of HRIS security in the workplace.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

706 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now