When attempting to ORDER BY on a Query of a Query, I get the following error
on ALL fields:
Query Manipulation Error Code = 0
STOREID is not a column that can be sorted on.
The query that I'm querying is a "Built Query" using QueryNew(),
QueryAddRow() and QuerySetCell() to create the final query.
Is this possible or am I doing something wrong?
Code:
<cfparam name="startdate"
default="#dateformat(dateadd('yyyy','-1',Now()),'mm/dd/yyyy')#">
<cfparam name="enddate" default="#dateformat(Now(),'mm/dd/yyyy')#">
<cfparam name="orderby" default="storeid">
<cfparam name="updn" default="ASC">
<cfquery dbtype="query" name="qNew">
SELECT * FROM qGetOrders
WHERE dateordered BETWEEN '#startdate#' AND '#enddate#'
ORDER BY #orderby# #updn#
</cfquery>
Joshua Miller
Web Development::Programming
Eagle Technologies Group, Inc.
www.eagletgi.com
[EMAIL PROTECTED]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Your ad could be here. Monies from ads go to support these lists and provide more
resources for the community. http://www.fusionauthority.com/ads.cfm
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