Index: includes/database.mysql.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/database.mysql.inc,v
retrieving revision 1.64
diff -u -p -r1.64 database.mysql.inc
--- includes/database.mysql.inc	4 Dec 2006 11:06:29 -0000	1.64
+++ includes/database.mysql.inc	27 Dec 2006 21:13:50 -0000
@@ -249,6 +249,9 @@ function db_error() {
  * database tables. Instead, this function is used to return a new unique ID
  * of the type requested. If necessary, a new sequence with the given name
  * will be created.
+ *
+ * Note that the table name should be in curly brackets to preserve compatibility
+ * with table prefixes. For example, db_next_id('{node}_nid');
  */
 function db_next_id($name) {
   $name = db_prefix_tables($name);
Index: includes/database.mysqli.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/database.mysqli.inc,v
retrieving revision 1.30
diff -u -p -r1.30 database.mysqli.inc
--- includes/database.mysqli.inc	4 Dec 2006 11:06:29 -0000	1.30
+++ includes/database.mysqli.inc	27 Dec 2006 21:14:50 -0000
@@ -234,6 +234,9 @@ function db_error() {
  * database tables. Instead, this function is used to return a new unique ID
  * of the type requested. If necessary, a new sequence with the given name
  * will be created.
+ *
+ * Note that the table name should be in curly brackets to preserve compatibility
+ * with table prefixes. For example, db_next_id('{node}_nid');
  */
 function db_next_id($name) {
   $name = db_prefix_tables($name);
Index: includes/database.pgsql.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/database.pgsql.inc,v
retrieving revision 1.42
diff -u -p -r1.42 database.pgsql.inc
--- includes/database.pgsql.inc	14 Dec 2006 13:26:41 -0000	1.42
+++ includes/database.pgsql.inc	27 Dec 2006 21:13:47 -0000
@@ -228,6 +228,9 @@ function db_error() {
  * database tables. Instead, this function is used to return a new unique ID
  * of the type requested. If necessary, a new sequence with the given name
  * will be created.
+ *
+ * Note that the table name should be in curly brackets to preserve compatibility
+ * with table prefixes. For example, db_next_id('{node}_nid');
  */
 function db_next_id($name) {
   $id = db_result(db_query("SELECT nextval('%s_seq')", db_prefix_tables($name)));