<cfquery....>
  SELECT *
     FROM MyTable
   WHERE ID = <cvfqueryparam value="#MyIDVar#" cfsqltype="cf_sql_integer">
</cfquery>

Cheers ;-)

Bryan Stevenson B.Comm.
VP & Director of E-Commerce Development
Electric Edge Systems Group Inc.
t. 250.920.8830
e. [EMAIL PROTECTED]

---------------------------------------------------------
Macromedia Associate Partner
www.macromedia.com
---------------------------------------------------------
Vancouver Island ColdFusion Users Group
Founder & Director
www.cfug-vancouverisland.com
  ----- Original Message -----
  From: Daniel Farmer
  To: CF-Talk
  Sent: Thursday, January 22, 2004 10:30 AM
  Subject: Re: some errors...

  this is a variable.
    ----- Original Message -----
    From: Jochem van Dieten
    To: CF-Talk
    Sent: Thursday, January 22, 2004 1:24 PM
    Subject: Re: some errors...

    Daniel Farmer said:
    > Here's my code... I've never used this tag before... not sure
    > exactly how it's used... I'm using some custom tags with this
    > setup... so basically the html code is being sent to  this query
    > template via the attributes.sql. Am I using the tag correctly?

    > <cfquery name="caller.#attributes.qname#"
    > datasource="#dadatasource#">
    >         <cfqueryparam value="#attributes.sql#">
    > </cfquery>

    You can't put a complete statement in a cfqueryparam, only variables:
    http://livedocs.macromedia.com/coldfusion/6.1/htmldocs/tags-b20.htm

    Jochem
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to