Click here to Skip to main content
15,921,716 members
Home / Discussions / Web Development
   

Web Development

 
GeneralRe: Tricky Page Reload Pin
devvvy5-Feb-03 12:08
devvvy5-Feb-03 12:08 
GeneralRe: Tricky Page Reload Pin
Steven M Hunt5-Feb-03 13:33
Steven M Hunt5-Feb-03 13:33 
GeneralRe: Tricky Page Reload Pin
devvvy5-Feb-03 13:56
devvvy5-Feb-03 13:56 
GeneralPlease help and help me ...! Pin
Thuy Dinh4-Feb-03 20:00
Thuy Dinh4-Feb-03 20:00 
GeneralRe: Please help and help me ...! Pin
Christian Graus4-Feb-03 21:02
protectorChristian Graus4-Feb-03 21:02 
GeneralRe: Please help and help me ...! Pin
Vasudevan Deepak Kumar4-Feb-03 21:29
Vasudevan Deepak Kumar4-Feb-03 21:29 
GeneralRe: Please help and help me ...! Pin
Thuy Dinh6-Feb-03 5:01
Thuy Dinh6-Feb-03 5:01 
QuestionADO-stored procedure - ASP - type mismatch? out-of-range? Pin
devvvy4-Feb-03 18:11
devvvy4-Feb-03 18:11 
I am suffering from a lot of pain doing this. And I have decided to bring this to you genius - with the belief that someone on this planet will safe me further trauma debuggin this script.

Dead | X|

Here's what i have on my ASP script:
'Connecting to Microsoft SQL Server:
oConn.ConnectionString = "Provider=sqloledb; Data Source=(local); Initial Catalog='dummyDB'; User ID=sa; Password=sa"
oConn.Open

'Update profile through stored procedure "sproc_ChangeProfile":
Set oCmd = Server.CreateObject("ADODB.Command")

With oCmd

.ActiveConnection = oConn
.CommandText = "dbo.sproc_ChangeProfile"
.CommandType = adCmdStoredProc


.Parameters.Append .CreateParameter("@old_login", adChar, adParamInput, 15, Request.Form("txtOldLogin") )
.Parameters.Append .CreateParameter("@login", adChar, adParamInput, 15, Request.Form("txtLogin") )
.Parameters.Append .CreateParameter("@password", adChar, adParamInput, 15, Request.Form("txtPasswd") )

.Parameters.Append .CreateParameter("@first_name", adChar, adParamInput, 50, Request.Form("first_name") )
.Parameters.Append .CreateParameter("@middle_name", adChar, adParamInput, 50, Request.Form("middle_name") )
.Parameters.Append .CreateParameter("@last_name", adChar, adParamInput, 50, Request.Form("last_name") )

.Parameters.Append .CreateParameter("@email1", adChar, adParamInput, 50, Request.Form("email1") )
.Parameters.Append .CreateParameter("@email2", adChar, adParamInput, 50, Request.Form("email2") )

.Parameters.Append .CreateParameter("@tel_home", adChar, adParamInput, 30, Request.Form("tel_home") )
.Parameters.Append .CreateParameter("@tel_office", adChar, adParamInput, 30, Request.Form("tel_office") )
.Parameters.Append .CreateParameter("@tel_fax", adChar, adParamInput, 30, Request.Form("tel_fax") )
.Parameters.Append .CreateParameter("@tel_cell", adChar, adParamInput, 30, Request.Form("tel_cell") )
.Parameters.Append .CreateParameter("@tel_pager", adChar, adParamInput, 30, Request.Form("tel_pager") )

.Parameters.Append .CreateParameter("@title", adChar, adParamInput, 100, Request.Form("title") )
.Parameters.Append .CreateParameter("@association", adChar, adParamInput, 50, Request.Form("association") )

.Parameters.Append .CreateParameter("@address_unit_num", adChar, adParamInput, 15, Request.Form("address_unit_num") )
.Parameters.Append .CreateParameter("@address_bldg_name", adChar, adParamInput, 50, Request.Form("address_bldg_name") )
.Parameters.Append .CreateParameter("@address_street_num", adChar, adParamInput, 15, Request.Form("address_street_num") )
.Parameters.Append .CreateParameter("@address_street", adChar, adParamInput, 100, Request.Form("address_street") )
.Parameters.Append .CreateParameter("@address_city", adChar, adParamInput, 100, Request.Form("address_city") )
.Parameters.Append .CreateParameter("@address_province", adChar, adParamInput, 100, Request.Form("address_province") )
.Parameters.Append .CreateParameter("@address_country", adChar, adParamInput, 100, Request.Form("address_country") )
.Parameters.Append .CreateParameter("@address_zipcode", adChar, adParamInput, 100, Request.Form("address_zipcode") )

.Parameters.Append .CreateParameter("@update_target", adInteger, adParamInput, 4, Request.Form("update_target"))

.Parameters.Append .CreateParameter("@error_status", adInteger, adParamOutput, 4, 0) 'OUTPUT: error status.


'Execute the stored procedure:
.Execute


End With


'Check return status:
If oCmd.Parameters("@error_status")=0 Then
'No error.
Else
'exception handling - please refer to stored procedure for error code interpretation.
bstatuscode=oCmd.Parameters("@error_status")
End If

Here's the declaration of the stored procedure in question:

CREATE PROCEDURE dbo.sproc_ChangeProfile(
@old_login char(15) =NULL,
@login char(15) =NULL,
@password char(15) =NULL,
@first_name char(50) =NULL,
@middle_name char(50) =NULL,
@last_name char(50) =NULL,
@email1 char(50) =NULL,
@email2 char(50) =NULL,
@tel_home char(30) =NULL,
@tel_office char(30) =NULL,
@tel_fax char(30) =NULL,
@tel_cell char(30) =NULL,
@tel_pager char(30) =NULL,
@title char(100) =NULL,
@association char(50) =NULL,
@address_unit_num char(15) =NULL,
@address_bldg_name char(50) =NULL,
@address_street_num char(15) =NULL,
@address_street char(100) =NULL,
@address_city char(100) =NULL,
@address_province char(100) =NULL,
@address_country char(100) =NULL,
@address_zipcode char(100) =NULL,
@update_target int=0,
@error_status int OUTPUT
)

I have checked and cross referenced many times. The types and parameters between the ASP and SQL script matches exactly. I have NO idea why I keep getting this following message when this script is executed:

ADODB.Command error '800a0bb9'

Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.

/submit_changed_profile.asp, line 39


Help!


norm
AnswerRe: ADO-stored procedure - ASP - type mismatch? out-of-range? Pin
Philip Patrick4-Feb-03 21:49
professionalPhilip Patrick4-Feb-03 21:49 
GeneralRe: ADO-stored procedure - ASP - type mismatch? out-of-range? Pin
devvvy4-Feb-03 22:19
devvvy4-Feb-03 22:19 
GeneralRe: ADO-stored procedure - ASP - type mismatch? out-of-range? Pin
Philip Patrick4-Feb-03 22:20
professionalPhilip Patrick4-Feb-03 22:20 
GeneralRe: ADO-stored procedure - ASP - type mismatch? out-of-range? Pin
devvvy5-Feb-03 0:19
devvvy5-Feb-03 0:19 
GeneralHtml - web site stuff Pin
tai fu4-Feb-03 1:22
tai fu4-Feb-03 1:22 
GeneralRe: Html - web site stuff Pin
DFU234-Feb-03 16:15
DFU234-Feb-03 16:15 
Generalcursor icon for mouse over Pin
devvvy3-Feb-03 23:36
devvvy3-Feb-03 23:36 
GeneralRe: cursor icon for mouse over Pin
Hesham Amin4-Feb-03 0:50
Hesham Amin4-Feb-03 0:50 
Generalestupido css margin issues Pin
(Steven Hicks)n+13-Feb-03 15:20
(Steven Hicks)n+13-Feb-03 15:20 
GeneralRe: estupido css margin issues Pin
DFU234-Feb-03 16:30
DFU234-Feb-03 16:30 
GeneralRe: estupido css margin issues Pin
Rohit  Sinha7-Feb-03 7:17
Rohit  Sinha7-Feb-03 7:17 
GeneralWSDL in VS.NET Pin
moredip3-Feb-03 6:22
moredip3-Feb-03 6:22 
Generalsetting value of file input field Pin
particle2k3-Feb-03 3:41
particle2k3-Feb-03 3:41 
GeneralRe: setting value of file input field Pin
Heath Stewart3-Feb-03 4:09
protectorHeath Stewart3-Feb-03 4:09 
GeneralA little help w/ Javascript and DHTML please Pin
georgiek502-Feb-03 2:21
georgiek502-Feb-03 2:21 
GeneralRe: A little help w/ Javascript and DHTML please Pin
Stephane Rodriguez.2-Feb-03 4:43
Stephane Rodriguez.2-Feb-03 4:43 
GeneralRe: A little help w/ Javascript and DHTML please Pin
georgiek502-Feb-03 7:11
georgiek502-Feb-03 7:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.