gasparrelli
Programmer
Hi! I am having some trouble trying to make code reusable: I have built stored procs in SQL to insert, update and perform other functions based on what variables get passed to them. The trouble that I'm having is that when I use cfprocparam ans specify the variable name using dbvarname, what CF finally passes to the server omits the variable name and only passes a series of variables.
In other words I call an SP called UpdCity with CFStoredProc, and include the following procparam:
<cfprocparam type="In" cfsqltype="CF_SQL_CHAR" value="#form.city#" dbvarname="@city" null="No">
What SQL finally gets is something akin to:
UpdCity Sacramento
Rather than the desired:
UpdCity @city=Sacramento
Anyone know why this is happening? Is it something I am doing wrong in the CF call or perhaps a problem with my ODBC driver? I can cut my number of SP's and lines of code to a fraction of what they would otherwise be if I can call them with named notation.
Any help is greatly appreciated on this as I am under a tight deadline and am new to using CF. Thanks!!! [sig][/sig]
In other words I call an SP called UpdCity with CFStoredProc, and include the following procparam:
<cfprocparam type="In" cfsqltype="CF_SQL_CHAR" value="#form.city#" dbvarname="@city" null="No">
What SQL finally gets is something akin to:
UpdCity Sacramento
Rather than the desired:
UpdCity @city=Sacramento
Anyone know why this is happening? Is it something I am doing wrong in the CF call or perhaps a problem with my ODBC driver? I can cut my number of SP's and lines of code to a fraction of what they would otherwise be if I can call them with named notation.
Any help is greatly appreciated on this as I am under a tight deadline and am new to using CF. Thanks!!! [sig][/sig]