HI everybody,,
Am stucked... I have a query with 9 rows. I need to store every row into a
different distinct variable. my query is listed below
cfquery name=getcs datasource=#datasource#
SELECT COUNT(s.id) AS cscount
FROMSociety s
WHERE s.gr='cs'
group by s.asst
/cfquery
cfoutput
I need to store every row
into a different distinct variable.
You probably don't, and should instead be using an array.
MyValues = ListToArray( ValueList( MyQuery.ColumnName ) )
Then you can do MyValues[1] to MyValues[9] to get at the variables.
If you *really* need to create individual
Thanks will do that then
I need to store every row
into a different distinct variable.
You probably don't, and should instead be using an array.
MyValues = ListToArray( ValueList( MyQuery.ColumnName ) )
Then you can do MyValues[1] to MyValues[9] to get at the variables.
If you
Just to throw out another solution, you can get the same result you
initailly tried by doing the following:
cfloop query=getcs
cfset variables[rowgetcs.currentRow] = getcs.cscount /
/cfloop
On Thu, May 28, 2009 at 7:58 AM, Peter Boughton bought...@gmail.com wrote:
I need to store every
And finally, you could simpy reference the original query using array
notation (e.g. getcs[cscount][1], getcs[cscount][2] etc) and avoid
the extra work.
mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/
2009/5/28 Scott Stroz boyz...@gmail.com:
Just to throw out
5 matches
Mail list logo