This brings up an interesting question for me. I tend to use recursive
functions frequently, and have even had to solve a problem very similar to
the original question posed in this thread. My take on the solution is the
following (in php):
itemIDitemparentID
First and foremost, we can't run queries inside of cfscript tags.
Bummer.
easy enough with a wrapper function.
Second, even if the query issue were resolved (and if you've got ideas for
work-arounds, I'd love to hear them), you've now got variable scope
issues.
A variable declared in a CFMX
On Wednesday, Jul 9, 2003, at 13:13 US/Pacific, Hagan, Ryan Mr
(Contractor ACI) wrote:
function list_categories( $parentId, $level ) {
cffunction name=list_categories
cfargument name=parentId type=numeric
cfargument name=level type=numeric
global $database, $connection;
Worth mentioning that you can use custom tags in a recursive manner. I have
several recursive tree generators on various versions of CF that use custom
tags, UDFs and CFC methods. custom tags and CFFUCTION-based UDFs (including
CFCs) can have CFQUERY tags in them, although if you're making a
Hagan, Ryan Mr (Contractor ACI) wrote:
I personally like this solution quite a bit. I know it has performance
issues, but I've never noticed any significant impact on server response,
even under heavy load.
I think it is an ugly workaround. SQL is a set oriented language and the
best way
5 matches
Mail list logo