diff options
author | Dries Buytaert <dries@buytaert.net> | 2008-10-06 10:56:35 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2008-10-06 10:56:35 +0000 |
commit | 9b23008a4adc890f4da64971232eca30c43c6271 (patch) | |
tree | 1d119b85673c37e4ecdaba7e90fa637328d13dbb | |
parent | c462ab100274487d934f9c81759c9035f50a05d6 (diff) | |
download | brdo-9b23008a4adc890f4da64971232eca30c43c6271.tar.gz brdo-9b23008a4adc890f4da64971232eca30c43c6271.tar.bz2 |
- Patch #300239 by Crell: updated documentation of db_insert().
-rw-r--r-- | includes/database/query.inc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/includes/database/query.inc b/includes/database/query.inc index 4abcc2037..ab0e623e7 100644 --- a/includes/database/query.inc +++ b/includes/database/query.inc @@ -360,6 +360,10 @@ class InsertQuery extends Query { * If the database does not support delayed INSERT queries, this method * has no effect. * + * Note that for a delayed query there is no serial ID returned, as it won't + * be created until later when the query runs. It should therefore not be + * used if the value of the ID is known. + * * @param $delay * If TRUE, this query is delay-safe and will run delayed on supported databases. * @return @@ -376,7 +380,9 @@ class InsertQuery extends Query { * @return * The last insert ID of the query, if one exists. If the query * was given multiple sets of values to insert, the return value is - * undefined. + * undefined. If the query is flagged "delayed", then the insert ID + * won't be created until later when the query actually runs so the + * return value is also undefined. */ public function execute() { |