<cfset var qLF = "" >
 <cfset dsn="it">
 <cfset un="that">
 <cfset pw="this">
  <cfquery name="qLF" datasource="#dsn#" username="#un#" password="#pw#">
  SELECT * FROM patterns ORDER BY parentID DESC
  </cfquery>
  <cfreturn qLF>

Heh, hi Taco btw.

umm, be careful and remember that if you use <cfset dsn=""> instead of
<cfset var dsn=""> then that DSN is now a global variable FOR That
cfc...

ie try the above and do a dump on the actual CFC afterwards :) just an FYI.


On Apr 5, 2005 2:47 PM, Taco Fleur <[EMAIL PROTECTED]> wrote:
>  <cfcomponent>
>  <!---
>      function getQLF
>      Generated by the CFC Recordset ColdFusion MX Extension
>      Mon Apr 04 22:08:12 GMT-0600 (Mountain Daylight Time) 2005
>      --->
>  <cffunction name="getQLF" output="false" access="private"
> returntype="query">
>   <cfset var qLF = "" >
>   <cfset dsn="it">
>   <cfset un="that">
>   <cfset pw="this">
>    <cfquery name="qLF" datasource="#dsn#" username="#un#" password="#pw#">
>    SELECT * FROM patterns ORDER BY parentID DESC
>    </cfquery>
>    <cfreturn qLF>
>  </cffunction>
>  </cfcomponent>
> 
> --
> Taco Fleur
> Senior Web Systems Engineer
> http://www.webassociates.com
> 
> -----Original Message-----
> From: dave [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, 5 April 2005 2:47 PM
> To: CF-Talk
> Subject: Re: cfc error
> 
> here it is
> 
>  <cfcomponent>
>  <!---
>      function getQLF
>      Generated by the CFC Recordset ColdFusion MX Extension
>      Mon Apr 04 22:08:12 GMT-0600 (Mountain Daylight Time) 2005
>      --->
>  <cffunction name="getQLF" output="false" access="private"
> returntype="query">  <cfset dsn="it">  <cfset un="that">  <cfset pw="this">
> 
>    <cfset var qLF = "" >
>    <cfquery name="qLF" datasource="#dsn#" username="#un#" password="#pw#">
>    SELECT * FROM patterns ORDER BY parentID DESC
>    </cfquery>
>    <cfreturn qLF>
>  </cffunction>
>  </cfcomponent>
> 
> ----------------------------------------
> From: Jon Austin <[EMAIL PROTECTED]>
> Sent: Tuesday, April 05, 2005 12:43 AM
> To: CF-Talk <[email protected]>
> Subject: Re: cfc error
> 
> Are all of your  statements grouped under your ?
> 
> //got nuthin
> 
> On Apr 5, 2005 2:40 PM, dave  wrote:
> > anyone know what this error means?
> >
> > Local variable qLF on line 18 must be grouped at the top of the function
> body.
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:201470
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to