ASP & SQL Server2000. (0x80040E10 And 0x80040E14)

  • Sam_M_M
  • Born
  • Born
  • Sam_M_M
  • Posts: 1
  • Loc: Amman-Jordan

Post 3+ Months Ago

Hello, I created an ASP page that does the following:
transfer data from one database to other database according to a specific given value (AccountNo).

I used command objects to execute my SQL statements, but when i use them, and error is shown to me, this error is only a Hexa number error, which i got confused from, and didn't know what to do. sometimes i get the error number: 0x80040E10
and sometimes the error number: 0x80040E14

what is the meaning for each error number?

My code is shown below:

'===================================

<%

dim fserv
dim sserv
dim fuser
dim suser
dim fpass
dim spass
dim accountNum

fserv = request.form("fserv")
sserv = request.form("sserv")
fuser = request.form("fuser")
suser = request.form("suser")
fpass = request.form("fpass")
spass = request.form("spass")
accountNum = request.form("accountNum")

dim fcon
dim scon
dim dbRS
dim SelectSQL
dim InsertSQL
dim UpdateSQL

set fcon = Server.CreateObject("ADODB.Connection")
fcon.ConnectionString = "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=IVR1;Data Source=IVR_DB1"
fcon.open

set scon = Server.CreateObject("ADODB.Connection")
scon.ConnectionString = "Provider=SQLOLEDB.1;Persist Security Info=False;User ID=sa;Initial Catalog=IVR2;Data Source=IVR_DB1"
scon.open

set dbRS = Server.CreateObject("ADODB.Recordset")

SelectSQL = "select * from InBoxSMSs WHERE AccountNo = '"+accountNum+"';"
set dbRS = fcon.Execute(SelectSQL)

if(dbRS.EOF) then
response.redirect "NoData.asp"
end if


dim fcom
dim scom
set fcom = Server.CreateObject("ADODB.Command")
fcom.ActiveConnection = scon

set scom = Server.CreateObject("ADODB.Command")
scom.ActiveConnection = fcon

dim DUMMY
DUMMY = ""

while not dbRS.EOF

InsertSQL = "insert into InBoxSMSs(SMS_Mobile, SMS_Text, SMS_RecievedDate, AccountNo, SMS_ReadDate) values ('"+CStr(dbRS("SMS_Mobile"))+"', '"+CStr(dbRS("SMS_Text"))+"', "+CStr(dbRS("SMS_RecievedDate"))+", '"+CStr(dbRS("AccountNo"))+"', NULL);"
UpdateSQL = "update InBoxSMSs set SMS_ReadDate = '"+CStr(Date())+"' WHERE AccountNo = '"+CStr(dbRS("AccountNo"))+"';"
fcom.CommandText = InsertSQL
scom.CommandText = UpdateSQL

fcom.Execute
scom.Execute

dbRS.Movenext
wend


%>

Error is in line: fcom.Execute (The first command execution)
'===================================
Note: Each SQL statement I have in my code is in one line for each not like what appears above, but please tell me what might the error be? is it in the SQL statements? using the single or double qoutes? or with the command objects? where the second command cobject execution is fine and it works correctly, but the first command object has the error shown above.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23455
  • Loc: Woodbridge VA

Post 3+ Months Ago

My fisrt step would be to do four Google searches

Google search 1: error + 0x80040E10
Google search 2: error + 0x80040E14
Google search 3: error number: 0x80040E10
Google search 4: error number: 0x80040E14

I'd be about 90% sure you'll find the answer to your quesions in the results from those searches.
  • yehya
  • Born
  • Born
  • yehya
  • Posts: 1
  • Loc: lebanon

Post 3+ Months Ago

hi samamman

your error is: "No value given for one or more required parameters"
test if you have a field not null in your DB

in plus,
you use CStr(dbRS("SMS_RecievedDate")) without put it between quotation even it is a string. if it is a date use CDate in place of CStr

Post Information

  • Total Posts in this topic: 3 posts
  • Users browsing this forum: No registered users and 122 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
cron
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.