epipko
02/07/2022, 5:21 PM<CFTRY>
<cfstoredproc procedure="UPDATE_PKG.MAIN_P" datasource="#REQUEST.prod#">
<cfprocparam type="In" value=#FORM.sales_order_number# cfsqltype="CF_SQL_INTEGER">
<cfprocparam type="In" value=#FORM.division_id# cfsqltype="CF_SQL_VARCHAR">
</cfstoredproc>
<cfoutput>
<h3 align="left">Success</h3>
<p></p><a href="#CGI.http_referer#">Go Back</a>
</cfoutput>
<CFCATCH TYPE = "Database">
<cfoutput>
Something went wrong :-( Contact your system administrator<br />
#cfcatch.queryError#
</cfoutput>
</CFCATCH>
</CFTRY>
Myka Forrest
02/07/2022, 5:23 PMcfcatch
to see what keys are available.Myka Forrest
02/07/2022, 5:25 PMtype
attribute is case-sensitive?aliaspooryorik
cfcatch
always exist. So your code is erroring when it runs, but then inside the error handling (the cfcatch
block) you are referencing something that doesn't exist.aliaspooryorik
epipko
02/07/2022, 5:46 PMMyka Forrest
02/07/2022, 5:47 PMepipko
02/07/2022, 5:52 PMepipko
02/07/2022, 5:54 PMaliaspooryorik
aliaspooryorik
<cftry>
<!--- run some code --->
<cfcatch type="database">
<!--- handle a database error --->
</cfcatch>
<cfcatch type="any">
<!--- handle any other type of error --->
</cfcatch>
</cftry>
epipko
02/07/2022, 6:05 PM