[support] Drupal: MySQL vs. PostgreSQL

larry at garfieldtech.com larry at garfieldtech.com
Wed Jul 21 17:46:08 UTC 2010


On 7/21/10 10:23 AM, Pierre Rineau wrote:

> D7 database layer supports foreign key definition, but like the old
> MyISAM engine, just ignore it (it's only semantics for the schema API).
> And for transactions, I don't know, I hope they did the twice magical
> functions start_transaction() and stop_transaction() (I really hope they
> did it).

Drupal 6 aims to be DB agnostic.  Drupal 7 aims to be storage-engine 
agnostic, meaning we can't even guarantee that the backend is SQL of any 
kind.  That makes relying on DB features of that sort (cascade delete, 
etc.) impossible.

D7 does include transaction support based on the design used by 
PressFlow.  You create a transaction object, and then everything is in a 
transaction until the end of the function when the transaction object 
goes out of scope.  Details are documented:

http://api.scratch.drupal.org/api/drupal/includes--database--database.inc/group/database/7

http://drupal.org/node/355875

(I think the former is more up to date.)

--Larry Garfield


More information about the support mailing list