That's something you should know about your DB.  There are reasons to
use transactions even if your DB doesn't support them.  For instance,
if you need 100% assurance that a series of statements will be
executed on a single connection, and no other statements will be
interspersed between them.  If you have a driver that understands
transactions (which the MySQL JDBC driver does) , and a
transaction-aware connection pool, you can use transactions for
exactly this effect, regardless of whether the DB actually supports
transactional logic (which MYISAM tables don't).  This allows you to
effectively use table locks and LAST_INSERT_ID() on MYISAM tables,
where you otherwise wouldn't be able to reliably do so, because of
connection pooling.

CFMX happens to single thread access to connections from the pool at a
request level, but BlueDragon doesn't do this.  On BD, every query
pulls a connection from the pool, runs the query, and then releases
the connection back to the pool.  (Whether that's efficient or not is
another discussion.)  Therefore if you want to use table locks, you
MUST use CFTRANSACTION.  If MySQL threw an error, then BD's pooling
mechanism would effectively prevent you from using MYISAM tables in
any sort of efficient way.

I'm willing to trust my knowledge of the DB for the ability to use the
database in these scenarios.

cheers,
barneyb

On Mon, 31 Jan 2005 21:14:57 +0100, Jochem van Dieten
<[EMAIL PROTECTED]> wrote:
> Barney Boisvert wrote:
> > MyISAM tables don't support transactions.
> 
> Exactly. But if you try to use a cftransaction on them, no error
> is thrown. So you only find out much later that rollbacks didn't
> work etc.
> 
> Jochem
> 

-- 
Barney Boisvert
[EMAIL PROTECTED]
360.319.6145
http://www.barneyb.com/

Got Gmail? I have 6 invites.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:192518
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to