The scenario: I have a local application, which updates a local database as a business process goes on. But I want the application also to update a remote database, with the details of this event, then set a flag in the local record that the record has been exported to the remote database. However I'm building error handling to provide for the possibility that the remote database might not be available. I dont want that to stop the local application, or it will close the business down. I want the business to go on, the customer satisfied and the web site can be updated later on when the internet connection is back up again
Does CFTRANSACTION handle the commit/rollback of both databases if any part of the queries fails? I would code it kind of like this: <cftransaction> <cfquery name="qRemoteInsert" datasource="remoteDSN"> INSERT into eventrecord yada yada yada </cfquery> <cfquery name="qlocalUpdate" datasource="localDSN"> Update eventrecord SET exportedToRemoteDB = true WHERE eventID = <cfqueryparam value="#thiseventID#" cfsqltype="cf_sql_integer"/> </cfquery> </cftransaction> -- Cheers Mike Kear Windsor, NSW, Australia Adobe Certified Advanced ColdFusion Developer AFP Webworks http://afpwebworks.com ColdFusion 9 Enterprise, PHP, ASP, ASP.NET hosting from AUD$15/month -- You received this message because you are subscribed to the Google Groups "cfaussie" group. To post to this group, send email to cfaussie@googlegroups.com. To unsubscribe from this group, send email to cfaussie+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/cfaussie?hl=en.