Skip to main content
nikos101
Inspiring
September 22, 2009
Answered

Is there an easy way to get the sql that is sent in UPDATE query

  • September 22, 2009
  • 1 reply
  • 1970 views

I have an  UPDATE query abbreviated for readability. Is there an easy way to get the sql that is sent? I use get that info for select sql in the debug view in cfeclipse but not for UPDATE.

  <cfquery debug="" name="q" datasource="#datasource#">

           
           
            UPDATE [BookingSystem].[dbo].[tbTrades]
   SET
      [status] = #MATCHED_STATUS#
     WHERE

            clientID    =   <cfqueryparam value="#arguments.clientID#" cfsqltype="cf_sql_integer"> AND
       
       


           
           
        </cfquery>

This topic has been closed for replies.
Correct answer Adam Cameron.

It might pay to read the docs for <cfquery> - http://livedocs.adobe.com/coldfusion/8/htmldocs/Tags_p-q_17.html#1102316 - focusing on the RESULT parameter.

Also read up on debugging in CF: http://livedocs.adobe.com/coldfusion/8/htmldocs/Debug_01.html

--

Adam

1 reply

Adam Cameron.Correct answer
Inspiring
September 22, 2009

It might pay to read the docs for <cfquery> - http://livedocs.adobe.com/coldfusion/8/htmldocs/Tags_p-q_17.html#1102316 - focusing on the RESULT parameter.

Also read up on debugging in CF: http://livedocs.adobe.com/coldfusion/8/htmldocs/Debug_01.html

--

Adam

nikos101
nikos101Author
Inspiring
September 22, 2009

thanks,

I get stuff like

    UPDATE[tbTrades]
   SET
      [status] = 1
     WHERE

            clientID    =   ? AND
       
           tradeDate = ? AND
            currencyPair = ?

How can I see past the ? where I use <cfqueryparam

ilssac
Inspiring
September 22, 2009

I'm not sure what you are using for this output.  But anything I have ever used would show the parameters after the query sql statement.