Re: Ordering query results
I'd do it with CFIF statements in the WHERE and ORDER BY clauses of your query, thus giving you the output you want based on what the user selects. Dave - Original Message - From: Carlo van Wyk <[EMAIL PROTECTED]> To: CF-Talk <[EMAIL PROTECTED]> Sent: Saturday, June 30, 2001 12:21 PM Subject: Ordering query results > I have a query from wich I want to order the results after the results have > been displayed. For Instance I want the user to order the search results by > the column name on which he clicks. > > How would one do this dynamically, and keep the order even when browsing > with recordsets? www.download.com does this very good. > > This is my query: > > SELECT * > FROM sl_software, sl_software_type > WHERE sl_software.type = sl_software_type.typeid > AND (ProgramName LIKE '%#searchcriteria#%' OR FileName LIKE > '%#searchcriteria#%') > > Thanks > > Carlo van Wyk > ColdFusion Developer > SOLVE Consulting > [w] www.solve.co.za > [c] +27 83 454 3533 > [t] +27 21 447 1108 > [f] +27 21 447 1128 > > Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ > Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists ~~ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
Re: Ordering query results
Two ways to do it... first, is Nate Weiss' CF_QuerySort tag... a definite must have for any CFer's toolbox... you can get it here http://devex.allaire.com/developer/gallery/info.cfm?ID=CA3470F8-2830-11D4-AA 9700508B94F380&method=Full But you might try something like this... ~~ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
RE: Ordering query results
Not sure what you mean by dynamically, but here is a cool IE only tag that I _think_ does what you need: http://www.activefeedback.com/af/products/activerecordset/userhelp/ActiveRec ordSetTest.cfm -Original Message- From: Carlo van Wyk [mailto:[EMAIL PROTECTED]] I have a query from wich I want to order the results after the results have been displayed. For Instance I want the user to order the search results by the column name on which he clicks. How would one do this dynamically, and keep the order even when browsing with recordsets? www.download.com does this very good. This is my query: SELECT * FROM sl_software, sl_software_type WHERE sl_software.type = sl_software_type.typeid AND (ProgramName LIKE '%#searchcriteria#%' OR FileName LIKE '%#searchcriteria#%') Thanks ~~ Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists
Ordering query results
I have a query from wich I want to order the results after the results have been displayed. For Instance I want the user to order the search results by the column name on which he clicks. How would one do this dynamically, and keep the order even when browsing with recordsets? www.download.com does this very good. This is my query: SELECT * FROM sl_software, sl_software_type WHERE sl_software.type = sl_software_type.typeid AND (ProgramName LIKE '%#searchcriteria#%' OR FileName LIKE '%#searchcriteria#%') Thanks Carlo van Wyk ColdFusion Developer SOLVE Consulting [w] www.solve.co.za [c] +27 83 454 3533 [t] +27 21 447 1108 [f] +27 21 447 1128 Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists