> Okay here is the thing.  I want to tagify this piece of code.
>
> <cfloop index = "i" list="#RETAILER_INFO.columnlist#">
> <CFSET temp = SetVariable("attributes.#i#",
> evaluate("RETAILER_INFO.#i#"))>
> </cfloop>
>
> so what I want to do is put the following in a tag...
>
> <cfloop index = "i" list="#caller.somequeryname.columnlist#">
> <CFSET SetVariable("caller.attributes.#i#",
> evaluate("somequeryname.#i#"))>
> </cfloop>
>
> (where in this case, somequeryname would be a server or cgi variable for
> RETAILER_INFO, which is the name attribute of my cfquery)
>
> So that I don't have to hard code the query name into the tag.  I
> am looking
> for a server variable for the Name="..." in a CFQUERY.

Why not just create the tag which goes through the loop (using the code I
originally supplied), then call it as <cf_CopyVariables
queryName="Retailer_Info">
This will mean that you can copy the fields into the Attributes scope from
the current row

You can't really use a CGI variable as most are server-side information, and
since a template can have an infinite number of queries, then there can't be
one variable for this - especially since they could all have the same column
names...

Using a template you can pass it query names in the form of a variable, just
as you would name a query with a variable
<cfquery name="#variables.queryName#" datasource="#variables.DSN#">
        ...
</cfquery>
<cf_CopyVariables queryName="#variables.queryName#">

Hope this provides some help

Philip Arnold
ASP Multimedia Limited
T: +44 (0)20 8680 1133

"Websites for the real world"

**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.
**********************************************************************


------------------------------------------------------------------------------
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to