shot in the dark...what if you remove the preservesingleQuotes() function from inside the <cfqueryparam>?
On 6/25/06, Will Tomlinson <[EMAIL PROTECTED]> wrote: > When I said not working I meant it returns a 0 recordcount when it shouldn't. > Here's the statement: > > <cfquery name="qry" blah blah... result="thesql"> > SELECT * FROM tblEvaluations WHERE tblEvaluations.Program IN ( > <cfif programlistlen> > <cfqueryparam cfsqltype="cf_sql_char" > value="#PreserveSingleQuotes(VARIABLES.programlist)#" list="yes"> > <cfelse> > '#FORM.programlist#' > </cfif> > ) > <cfif FORM.selectGender NEQ "All"> > AND tblEvaluations.Gender = '#FORM.selectGender#' > </cfif> > <cfif FORM.selectAge NEQ "All"> > AND tblEvaluations.Age = '#FORM.selectAge#' > </cfif> > </cfquery> > > A dump of thesql shows this: > > SQL SELECT * FROM tblEvaluations WHERE tblEvaluations.Program IN ( > ?,?,?,? ) > SQLPARAMETERS > array > 1 'ITN' > 2 'CSC' > 3 'CIS' > 4 'NET' > > If I remove the cfqueryparam, it works like a champ. > > Thanks for takin the time charlie! > > Will > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:244759 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=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

