I figured it out phil
-----Original Message----- From: Phillip Perry [mailto:[EMAIL PROTECTED] Sent: Saturday, November 27, 2004 5:42 PM To: CF-Talk Subject: cfmail sending 1 too many emails I have a cfmail that is "supposed" to send 2 emails to 1 person based on an ID#. I have confirmed that the output is showing only 2 id numbers but it is repeating 1 of them. This is what I have for code. I'm surrounding the cfmail tags with cfloop query="myquery" to get the email address(among other things). Here's the jist of it..... <cfquery datasource="#mydbname#" name="GetUsers"> SELECT * FROM contacts,ImageList WHERE contacts.contact_id = ImageList.contact_id </cfquery> <cfif GetUsers.RecordCount IS NOT 0> <CFLOOP QUERY="GetUsers" ><BR><cfmail FROM="[EMAIL PROTECTED]" SERVER="mail.applewoodcommunity.com" SUBJECT="The Applewood Community - Your Monthly Statement" TO="#GetUsers.email_address#" TYPE="HTML" WRAPTEXT="45">...yadda yadda yadda...</cfmail></cfloop></cfif> <cfquery datasource="#mydbname#" name="GetUsers2"> SELECT * FROM contacts,coupons WHERE contacts.contact_id = coupons.contact_id </cfquery> <cfif GetUsers2.RecordCount IS NOT 0> <CFLOOP QUERY="GetUsers2"><cfmail FROM="[EMAIL PROTECTED]" QUERY="GetUsers" SERVER="mail.applewoodcommunity.com" SUBJECT="The Applewood Community - Your Monthly Statement" TO="#GetUsers2.email_address#" TYPE="HTML" WRAPTEXT="45" >...yadda yadda yadda...</cfmail></cfloop></cfif> Thanks Phil ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Special thanks to the CF Community Suite Gold Sponsor - CFHosting.net http://www.cfhosting.net Message: http://www.houseoffusion.com/lists.cfm/link=i:4:185496 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54