according to the error message, you're missing a closing quote after
'changeProduct' and '17-Sep-07'.
are you sure those quotes are in your code?
On 9/17/07, Richard Colman <[EMAIL PROTECTED]> wrote:
> I want to log the sql text of various queries into a log table.
>
> When I try:
>
> <cfset sqltext="Update labview set product_ID=#form.product_ID# where
> ProdOrd_id=#form.prodOrd_ID#">
>
> <cfquery name="ChangeLog" datasource="#application.datasource#">
> insert into ChangeLog(actor, ChangeText, UpdateDate)
> Values('#actor#','#sqltext#','#datenow#')
> </cfquery>
>
> I get errors like:
>
> Incorrect syntax near the keyword 'Update'.
>
> insert into ChangeLog(actor, ChangeText, UpdateDate)
> Values('changeProduct,'Update project set product_ID=18 where
> project_id=3016','17-Sep-07)
>
>
> Is there some easy way to do this?
>
> Rick Colman
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Get involved in the latest ColdFusion discussions, product
development sharing, and articles on the Adobe Labs wiki.
http://labs/adobe.com/wiki/index.php/ColdFusion_8
Archive:
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:288673
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4