Peter Amiri
03/31/2022, 4:49 PM<!--- Wrapper for the CFSTOREDPROC tag. --->
<cffunction name="cfmlStoredProd" returntype="any" access="private" output="false">
<cfargument name="procedure" type="string" required="true">
<cfargument name="body" type="string" required="true">
<cfset local.rv = StructNew()>
<cfstoredproc datasource="mydatasource" procedure="#arguments.procedure#">
<cfprocparam value="#arguments.body#" cfsqltype="cf_sql_varchar" type="in">
<cfprocparam variable="local.rv.result" cfsqltype="cf_sql_varchar" type="out">
<cfprocresult name="local.rv.query" resultset=2>
</cfstoredproc>
<cfset local.rv.result = DeSerializeJson(local.rv.result)>
<cfreturn local.rv>
</cffunction>
Adam Cameron
<cfstoredproc>
to call PGSQL procs", and the original example code is in tags? And yer not really addressing the OP's question, which was how to call
a proc as opposed to using <cfstoredproc>
?