Brilliant.  I'll put this in the wiki page.

David

On Apr 10, 7:41 am, Vince Bonfanti <[email protected]> wrote:
> The Microsoft JDBC driver doesn't like the "@" when you specify the
> DBVARNAME attribute in the CFPROCPARAM tag. Remove the "@" and just specify
> DBVARNAME="id" and it will work.
>
> On Sat, Apr 9, 2011 at 8:55 PM, David Kanter <[email protected]> wrote:
> > Happy to share code:
>
> > I get a General SQL Error with the following message: "Parameter @id
> > was not defined for stored procedure rwtadmin.xcursus_getthread."  THe
> > SQL State is S1093.
>
> > The rwtadmin.xcursus_getthread procedure takes as input:
>
> > @id INT
> > @threadid INT
> > @roomid TINYINT
> > @showfullthread BIT=0
> > @hideflaggedposts BIT=0
> > @nextprev INT
>
> > It is called in the following context:
>
> > <cfinclude template="functions.cfm">
> > <cfif isdefined("url.entryid")><cfset url.id = url.entryid></cfif>
> > <cfparam name="url.id" type="numeric">
> > <cfparam name="url.threadid" type="numeric">
>
> > ...irrelevant code snipped
>
> > <cfstoredproc procedure="rwtadmin.xcursus_getthread"
> > datasource="#request.ds#" returncode="yes">
> >     <cfprocparam type="in" value="#url.id#"
> > cfsqltype="CF_SQL_INTEGER" null="No" dbvarname="@id">
> >     <cfprocparam type="in" value="#url.threadid#"
> > cfsqltype="CF_SQL_INTEGER" null="No" dbvarname="@threadid">
> >     <cfprocparam type="in" value="#url.roomid#"
> > cfsqltype="CF_SQL_INTEGER" null="No" dbvarname="@roomid">
> >     <cfprocparam type="in" value="#session.forumsettings.showthread#"
> > cfsqltype="CF_SQL_BIT" null="No" dbvarname="@showfullthread">
> >     <cfprocparam type="in" value="#hideflaggedposts#"
> > cfsqltype="CF_SQL_BIT" null="No" dbvarname="@hideflaggedposts">
>
> > ...irrelevant code snipped
>
> >     <cfprocresult name="detail" resultset="1">
> >  <cfprocresult name="posts" resultset="2">
> > </cfstoredproc>
>
> > Like I said, it works perfect in production, but sure not on my dev
> > system.
>
> > David
>
>

-- 
official tag/function reference: http://openbd.org/manual/
 mailing list - http://groups.google.com/group/openbd?hl=en

Reply via email to