[development] auto_increment

Knite knite at e-lai.com
Mon Dec 12 08:54:42 UTC 2005

This has probably been discussed in depth before, and I've found a few
nodes on drupal.org that captured some of the ideas, but I'm relatively
new to this list, so please forgive me and enlighten me if there's more
history I should know about.

AUTO_INCREMENT looks like a database feature that is supported in the
databases that drupal currently supports, namely mysql and pgsql.  From
what I gather from documentation at mysql.org and from previous comments
in our forums, it seems that AUTO_INCREMENT is an improvement over the
current system of creating nid's using the sequence table (and having to
lock it).

I'd like to look into moving drupal to use auto-increment instead of
table locking, for both performance reasons (1 query vs 3) and webhost
compatibility reasons.  (There are some webhosts that do not grant LOCK
TABLE permission.)

Has anyone attempted this conversion before?  Any words of advice?  Is
this something that's supposed to be left to the core developers?


More information about the development mailing list