cfmail questions
I have a query where I determine the number of days a request is still open. Here is the partial query :
SELECT DISTINCT
requestNumber,
DATEDIFF(day, date_arrived, GETDATE()) + 1 AS daysOpen
email,........
I then use cfmail to send an email to each email address. In the body of the email, I want to break it up into three categories based on the daysOpen
So I have this :
<cfif qry.daysOpen GTE 5 and LT 10>
<cfoutput>display something here in GREEN..etc</cfoutput>
</cfif>
<cfif qry.daysOpen GTE 10 and qrydaysOpen LTE 15>
<cfoutput>display something here in BLUE, etc</cfoutput>
</cfif>
<cffi qry.daysOpen GTE 15>
<cfouput>display somehting here in RED ,etc</cfoutput>
</cfif>
So for each email sent, the recipient show see three outputs, each in a different color.
However, this is not working and only the blue color is showing. I know there are daysOpen for the others also, but everything falls into the blue cateogry,
even daysOpen of 6, which according to the logic, should be green.
What am I doing wrong ? The logic makes sense to me but I guess it is incorrect. What do I need to do to get the three categories ?
