[thelist] Freebie ASP/StoredProc Tip

J J squid_66 at yahoo.com
Tue Jul 3 16:49:01 CDT 2001


I don't know, I've always coded them even simpler than
that, without much performance difference:

SQL = "EXEC myquery '" & var1 & "', '" & mydate & "',
'" & somename & "', '" & var2 & "' "
SET myRS = dataConn.Execute(SQL)

Then the SP looks for the above mentioned parameters
and builds the query from there. 

ADO is a pain in the arse at times.  :)




--- "Warden, Matt" <mwarden at mattwarden.com> wrote:
> Three headaches later, I figure out what my problem
> was...
> 
> <tip type="Calling MS SQL Server Stored Procedures
> from ASP">
> 
> When calling parameterized stored procedures from
> ASP, don't try hard. Send
> all strings. Not SQL strings. *ASP datatype*
> strings:
> 
> set param =
>
cmd.CreateParameter("param",adVarChar,adParamInput,100,"value")
> 
> As opposed to:
> 
> set param =
>
cmd.CreateParameter("param",adVarChar,adParamInput,100,"'value'")
> 

__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/




More information about the thelist mailing list