I'm building a top 10 leaderboard for contest entries and am
having some trouble with the sorting on my query. My Query is
almost working perfectly, however it doesn't seem to be ordering by
my new variable, 'entries'. Am I missing something somewhere, or is
my syntax correct? (it doesn't display at all unless I put the
single quotes on the variable entries).
<cfquery name="entry_count" datasource="clients">
select reg_id, count(reg_id) as entries
from targus_promo_entry
group by reg_id
order by 'entries' DESC
</cfquery>
Does anyone have any ideas???
Allison