You could also pass the order by via URL, and that would cut the cfcases by half.
On 9/17/07, Jochem van Dieten <[EMAIL PROTECTED]> wrote: > Vince Collins wrote: > > > > That suggestion works. However, in an example of a query with 10 > > columns and assuming you want to allow desc and asc, does anyone have a > > more conscience way other than 20 cfcase statements? > > Check if your database support ordering by the ordinal number of the > column in the resultset, i.e. the following sorts by t.B: > SELECT > t.A > , t.B > , t.C > FROM > table t > ORDER BY > 2 > > Jochem > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Create robust enterprise, web RIAs. Upgrade to ColdFusion 8 and integrate with Adobe Flex http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJP Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:288619 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4