Here's a tip - uppercase all the column names in your second query (as in FRWMAX > #WEIGHT#). There IS a case sensitivity problem.
Mark -----Original Message----- From: James Sleeman [mailto:[EMAIL PROTECTED]] Sent: Monday, February 18, 2002 3:51 PM To: CF-Talk Subject: Query of Query problem Anybody know if this is a known bug in CF ? This query <CFQUERY DBTYPE="QUERY" NAME="Q_Dump"> SELECT * FROM Q_Table WHERE FrWMin <= #Weight# AND ((FrWMax > #Weight#) OR (FrWMax = '')) </CFQUERY> produces a single row with value of 15.0 in the FrZWPrice field but this query <CFQUERY DBTYPE="QUERY" NAME="Q_Price"> SELECT Max(FrZWPrice) AS Price FROM Q_Table WHERE FrWMin <= #Weight# AND ((FrWMax > #Weight#) OR (FrWMax = '')) </CFQUERY> ignores the where clause and simply returns the maximum FrZWPrice, which in this instance is 55.0 James Sleeman Innovative Media Ltd Phone: (03) 377 6262 http://www.websolutions.co.nz/ CAUTION: The information contained in this email message is confidential and may be legally privileged. If the reader of this message is not the intended recipient you are notified that any use, dissemination, distribution or reproduction of this message is prohibited. If you have received this message in error please notify the sender immediately and destroy the original message and any attachments. Views expressed in this communication may not be those of Innovative Media Ltd. ______________________________________________________________________ Dedicated Windows 2000 Server PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER Instant Activation � $99/Month � Free Setup http://www.pennyhost.com/redirect.cfm?adcode=coldfusiona FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Archives: http://www.mail-archive.com/[email protected]/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

