No it's not overkill.  You could be passing in the argument as a form or url 
scoped variable for example:

<cfinvoke component="mycomponent"
    method="function"
    field_value="#url.field_value#">

If you just cfqueryparam everything you don't have to worry about it.


-- Josh



----- Original Message ----- 
From: "Hunsaker, Michael Scott" <[EMAIL PROTECTED]>
To: "cf-talk" <[email protected]>
Sent: Tuesday, September 30, 2008 1:21 PM
Subject: cfqueryparam within a cfc


> Hello -
>
> We are consistently using the CFQUERYPARAM tag in our code but not within 
> out CFCs. Here's a quick example:
>
> <cfcomponet>
>  <cffunction name="function">
>    <cfargument name="field_value" type="numeric" required="yes">
>
>    <cfquery name="get">
>      SELECT * FROM TABLE WHERE field = <cfqueryparam value="#field_value#" 
> cfsqltype="cf_sql_integer">
>    </cfquery>
>  </cffunction>
> </cfcomponent>
>
> Is this over-kill or good practice?
>
> Thanks!
>
> Mike
>
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:313299
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to