Let me format that code a little better:

<cfset newRow  = QueryAddRow(teamStandings, 1)>
 <!--- set the cells in the query row --->
 <cfset temp = QuerySetCell(teamStandings, "site_id", #site_id#,
#loop_count#)>
 <cfset temp = QuerySetCell(teamStandings, "name", #orginization_name#,
#loop_count#)> 
 <cfset temp = QuerySetCell(teamStandings, "wins", #wins#, #loop_count#)>
 <cfset temp = QuerySetCell(teamStandings, "losses", #losses#,
#loop_count#)>
 <cfset temp = QuerySetCell(teamStandings, "ties", #ties#, #loop_count#)>
 <cfset temp = QuerySetCell(teamStandings, "dist_wins", #dist_wins#,
#loop_count#)>
 <cfset temp = QuerySetCell(teamStandings, "dist_losses", #dist_losses#,
#loop_count#)>
 <cfset temp = QuerySetCell(teamStandings, "dist_ties", #dist_ties#,
#loop_count#)>
 
 <cfset loop_count = loop_count + 1>
</cfloop>


<cfquery dbtype="Query" name="Standings">
 SELECT
  site_id,
  name,
  wins,
  losses,
  ties,
  dist_wins,
  dist_losses,
  dist_ties
 FROM teamStandings
 ORDER BY dist_wins
</cfquery>

-----Original Message-----
From: Ryan Kime [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, October 03, 2002 9:23 AM
To: CF-Talk
Subject: QofQ weirdness when using QueryNew


OK, I really need some help on this one. 

I have a query I create on the fly using QueryNew/QueryAddRow/QuerySetCell.
Everything is fine until I try to use a cfquery with dbtype="Query" on the
created query to order the results - it throws a QofQ runtime error. If I
comment out the cfquery and call the original query created with QueryNew,
it runs fine and spits out the data (albeit unordered).

I could really use some insight on this. I need to get that query in a
particular ordered format and time is breathing down my neck.


Here's a code snippet, it dies right on the <cfquery> tag saying
"Unsupported Numeric type conversion"....yet it worked fine in CF5:

<cfset newRow  = QueryAddRow(teamStandings, 1)>
 <!--- set the cells in the query row --->
 <cfset temp = QuerySetCell(teamStandings, "site_id", #site_id#,
#loop_count#)>  <cfset temp = QuerySetCell(teamStandings, "name",
#orginization_name#, #loop_count#)>  <cfset temp =
QuerySetCell(teamStandings, "wins", #wins#, #loop_count#)>  <cfset temp =
QuerySetCell(teamStandings, "losses", #losses#, #loop_count#)>  <cfset temp
= QuerySetCell(teamStandings, "ties", #ties#, #loop_count#)>  <cfset temp =
QuerySetCell(teamStandings, "dist_wins", #dist_wins#, #loop_count#)>  <cfset
temp = QuerySetCell(teamStandings, "dist_losses", #dist_losses#,
#loop_count#)>  <cfset temp = QuerySetCell(teamStandings, "dist_ties",
#dist_ties#, #loop_count#)>
 
 <cfset loop_count = loop_count + 1>
</cfloop>


<cfquery dbtype="Query" name="Standings">
 SELECT
  site_id,
  name,
  wins,
  losses,
  ties,
  dist_wins,
  dist_losses,
  dist_ties
 FROM teamStandings
 ORDER BY dist_wins
</cfquery>


Ryan 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
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

Reply via email to