I have a large block of code within a <cfquery>
At the end of this block of code I have a <cfif status is 1> that evaluates fine.....
BUT if I wrap this entire block of code (including the CFQuery) in a <CFLoop query=someQuery>
The cfif fail to evaluate "1" no matter how I present that cfif.
Why? All my <cfif>'s inside the <cfquery> block still evaluate fine.
??
Here's a brief example of the code.
<cfquery name="dNames">
<!--- CFLOOP starts --->
<cfloop query="dNames">
<cfset SID = #dNames.NameID#>
<cfquery name="dReport" datasource="dsn">
SELECT * FROM Report ......
</cfquery>
<cfif x=something><cfset Down = something></cfif>
<!--- Query Loop Starts Here --->
<cfoutput query="dReport">
<cfif cDate eq 0>
<cfset cDate = something>
<cfelse>
<cfset cDateTime = #StatusTimeEdit#>
</cfif>
</cfoutput>
<!--- Query Loop Ends Here --->
***THIS IS THE ONLY <CFIF> THAT FAILS !!!!!!! ****
<cfif cStatus is 1>
<cfset UP = something>
</cfif>
</cfloop>
This code example isn't meant to be followed....it's only to represent the positioning of the code blocks. Basically why does the final CFIF evaluate fine with the inner CFQuery alone and then fail when I wrap all the code witha "CFLoop query =" ???
Thanks,
-=-=-=-=-=-=-=-=-=-=-=-=-=-
Apex Systems Consulting
e-Solutions for Small Business
At the end of this block of code I have a <cfif status is 1> that evaluates fine.....
BUT if I wrap this entire block of code (including the CFQuery) in a <CFLoop query=someQuery>
The cfif fail to evaluate "1" no matter how I present that cfif.
Why? All my <cfif>'s inside the <cfquery> block still evaluate fine.
??
Here's a brief example of the code.
<cfquery name="dNames">
<!--- CFLOOP starts --->
<cfloop query="dNames">
<cfset SID = #dNames.NameID#>
<cfquery name="dReport" datasource="dsn">
SELECT * FROM Report ......
</cfquery>
<cfif x=something><cfset Down = something></cfif>
<!--- Query Loop Starts Here --->
<cfoutput query="dReport">
<cfif cDate eq 0>
<cfset cDate = something>
<cfelse>
<cfset cDateTime = #StatusTimeEdit#>
</cfif>
</cfoutput>
<!--- Query Loop Ends Here --->
***THIS IS THE ONLY <CFIF> THAT FAILS !!!!!!! ****
<cfif cStatus is 1>
<cfset UP = something>
</cfif>
</cfloop>
This code example isn't meant to be followed....it's only to represent the positioning of the code blocks. Basically why does the final CFIF evaluate fine with the inner CFQuery alone and then fail when I wrap all the code witha "CFLoop query =" ???
Thanks,
-=-=-=-=-=-=-=-=-=-=-=-=-=-
Apex Systems Consulting
e-Solutions for Small Business