While I have not tested this just now, I am pretty sure that it will not run... It throws an error telling you that you cannot have different DSN queries in the same transaction. I am on MX 7, maybe it is new? I only knew this happens because I have been doing a lot of data transfer stuff lately.
Of course, I could be thinking of something else, as I said, I didn't just test this. -----Original Message----- From: Dave Watts [mailto:[EMAIL PROTECTED] Sent: Wednesday, February 21, 2007 4:14 PM To: CF-Talk Subject: RE: cftransaction and two datasources > I have a question. I have a application where on one template I have > several inserts into one datasource are wrapped inside a > cftransaction. At the end of the loop, but outside the cftransaction, > I have an update of a record in a second datasource, marking it as > viewed. My question, is can I have the update query inside my > transaction even though it is a separate DSN? You can, but it won't be treated as part of that transaction. That is, it'll run, but it won't depend on other queries to succeed, or cause other queries to be rolled back if it fails. If you want to have transactions across multiple datasources that point to the same database server, that can be pretty easy to set up, as long as one of the datasources uses an account with rights to the database used by the other datasource. If they point to separate database servers, you need a distributed transaction coordinator of some sort, which is usually not easy to set up. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ Fig Leaf Software provides the highest caliber vendor-authorized instruction at our training centers in Washington DC, Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location. Visit http://training.figleaf.com/ for more information! ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Deploy Web Applications Quickly across the enterprise with ColdFusion MX7 & Flex 2. Free Trial http://www.adobe.com/products/coldfusion/flex2/ Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:270395 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

