summaryrefslogtreecommitdiff
path: root/includes/database.inc
Commit message (Collapse)AuthorAge
* #16542, add db rewriting for menus, patch by chxGerhard Killesreiter2006-04-07
| | | | fixes 57406 too
* #42000, misssing underscore, found by rumpGerhard Killesreiter2006-03-26
|
* #42000, docs update, by meGerhard Killesreiter2006-03-26
|
* #42000, Watchdog can't log errors when using db_set_active(non-default), ↵Gerhard Killesreiter2006-03-26
| | | | patch by Chris Johnson and myself
* - Patch #51850 by chx, webchick et al: fixed various problems with ↵Dries Buytaert2006-03-08
| | | | db_rewrite_sql, made db_rewrite_sql slightly more robust.
* - Patch #41644 by chx: critical bug: db_rewrite_sql had a bad regex.Dries Buytaert2006-01-08
|
* - Patch #40631 by Chris Johnson: is_array() slower than isset() or empty().Dries Buytaert2005-12-14
|
* - Patch #39257 by merlinofchaos: node_access rewrite breaks with FROM_UNIXTIME.Dries Buytaert2005-11-29
|
* - Patch #10407 by Cvbge: fixed cache problems with PostgreSQL.Dries Buytaert2005-11-27
|
* - Patch #29910 by m3avrck, nsk, Thomas et al: added a mysqli database ↵Dries Buytaert2005-09-12
| | | | | | backend for use with PHP5 and MySQL 4.1 and above. NOTE: I don't have MySQL 4.1 setup at the moment so I could _not_ test this patch. Luckily, various people reported that it works.
* - Patch #30122 by m3verick: changed include_once()'s to include "./$file"Dries Buytaert2005-09-08
| | | | for performance's sake.
* - Patch #29385 by chx: no ?> add end of files.Dries Buytaert2005-08-25
|
* - #27231: Friendly DB error screens.Steven Wittens2005-07-27
|
* - Patch #18213 by chx: boostrap system. Modified to work with HEAD, tidiedDries Buytaert2005-06-22
| | | | | | | up the documentation a little. chx: can you double-check whether the global $conf variable is secure? (That is, make sure it can't be send using the URL or something.)
* - Patch #19609 by Daniel: fix problem with database prefixingDries Buytaert2005-04-08
|
* - Fixing broken search after sql rewrite patchesSteven Wittens2005-02-19
| | | | - Minor code style fixes.
* - #16111: bad quotes in db_rewrite_sqlSteven Wittens2005-02-05
|
* - Patch #16111 by chx: fixed some bugs in the db_rewrite_sql() code.Dries Buytaert2005-01-31
|
* - Patch #16111 by chx: PHPdoc/documentation improvements.Dries Buytaert2005-01-30
|
* - Patch #16111 by chx: generalized node_rewrite_query to db_rewrite_query.Dries Buytaert2005-01-29
|
* - Patch #13020 by chx: let Drupal handle multiple database layers.Dries Buytaert2004-12-30
| | | | - Removed the PEAR database backend. It's no longer being used/maintained.
* - Patch #13581 by Steven: Db_query() allows a variable amount of parameters ↵Dries Buytaert2004-11-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | so you can pass the query arguments in. There is however an alternative syntax: instead of passing the query arguments as function arguments, you can also pass a single array with the query arguments in it. For example the following two statements are equivalent: db_query($query, $a, $b, $c); db_query($query, array($a, $b, $c)); This usage is particularly interesting when the query is constructed dynamically, and the amount of arguments to pass varies. In that case we use the second method to avoid using call_user_func_array(). This behaviour is not documented explicitly, but it is used in several places. However, db_query_range() and pager_query() do not support this syntax properly, which means there are several pieces of code which still revert to the ugly call_user_func_array() call. This patch updates db_query_range() and pager_query() so they support the array-passing method. I also added documentation about this method to each of the db functions. I also cleaned up the code for db_query (it was weird and hard to understand) and moved db_query() and db_queryd() from database.xxxxx.inc to database.inc: it was the same between both mysql and pgsql, as it doesn't do anything database specific. It just prefixes the tables and inserts the arguments. The actual db query is performed in _db_query(), which is still in database.xxxxx.inc. Finally, I updated several places with the new syntax, and the code is a lot cleaner. For example: - array_unshift($params, "SELECT u.* FROM {users} u WHERE $query u.status < 3"); - $params[] = 0; - $params[] = 1; - $result = call_user_func_array('db_query_range', $params); + $result = db_query_range("SELECT u.* FROM {users} u WHERE $query u.status < 3", $params, 0, 1); and - return call_user_func_array('db_query_range', array_merge(array($query), $args, array((int)$pager_from_array[$element], (int)$limit))); + return db_query_range($query, $args, (int)$pager_from_array[$element], (int)$limit); I've tested it on mysql. I didn't alter the actual db behaviour, so pgsql should be okay too. This patch is important because many people avoid the call_user_func_array() method and put data directly into the db query. This is very, very bad because the database prefix will be applied to it, and strip out braces. It's also generally bad form as you have to call check_query() yourself. With the new, documented syntax, there is no more excuse to put data directly in the query.
* - Patch #10663 by JonBob: documentation improvements: fixed some typos and ↵Dries Buytaert2004-09-09
| | | | improved consistency to the use of Doxygen/api.module commands in the comments.
* - Patch #10622 by Adrian: fixes various PostgreSQL related problems.Dries Buytaert2004-09-08
| | | | | | | | | | | | | 1) Menu problems with Postgres (this is a highly critical 1 line fix) 2) Archive module fails with Postgres 3) Postgres setup problems - changes to database.pgsql (although i made these changes myself before finding this patch) 4) Book module fails with Postgres 5) Postgres problems following creation of a new type of user - which is actually about a taxonomy.module bug. 6) Creating accregator_item_table in PostgreSQL 7) Postgres - Polls not displayed on Poll Page 8) Blog module has sql errors with postgres This should not affect MySQL users (hopefully).
* - Patch #9287 by JonBob: made the code style in the three database include ↵Dries Buytaert2004-07-14
| | | | files consistent with Drupal standards, and adds a wealth of Doxygen-style comments to aid developers in writing solid database access code using the API.
* - Patch #7575 by ax: not in global scope, making updates fail.Dries Buytaert2004-05-06
|
* - Patch by Adrian: added support for multiple database connections.Dries Buytaert2004-04-30
|
* - Modifies path.module to get rid of pgsql reserved word. Patch by Adrian.Dries Buytaert2003-10-01
| | | | | | | | | | - Updates database.pgsql and database.mysql to work with current cvs. Patch by Adrian. - Updates update.php to be able to update postgres from 4.2 to current. Patch by Adrian. - Small fixes by me.
* - Committed Moshe's selective table rewriting patch. Makes it possible toDries Buytaert2003-08-26
| | | | share some database tables but not others.
* - Committed a slightly modified version of Slavica's table prefix patch.Dries Buytaert2003-07-10
|
* - node.module:Dries Buytaert2001-11-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | + Changed node_form() to use good ol' tables instead of div/CSS-tags. + Revised the "revision API": I think we have both an easy and powerful API now that should make everyone happy. + Improved the usability of the rollback functionality a bit. + Removed the "view node" link from the "node overview" page in the admin section and added a "delete node" link instead. + Added a few missing translations; there might be missing more translations though. - book.module: + Made the book module use the "revision API" instead of having it poke and use the innards and underlying details of the revision system. - queue.module: + Made the queue module use the improved revision number. - module.inc: + Applied Moshe's patch: added more arguments to module_invoke() - mail-to-sql.pl: + Added support for more header fields and for folded fields Notes: - no database updates required
* - Made some improvements/updates to the database abstraction layer.Dries Buytaert2001-10-31
|
* - added the CVS keyword $Id$ to all files to make future version trackingKjartan Mannes2001-10-20
| | | | easier. Also changed the <? tag to <?php in some cases.
* - Small improvement to db_query() to make debuging queries a bit more easy.Dries Buytaert2001-10-14
|
* - added sequence tablesDries Buytaert2001-10-11
| | | | | | | | - fixed bug in node_page() - fixed bug in db_result() - fixed rss glitch
* - PEAR-ification of Drupal by claw: you can now host Drupal on a wideDries Buytaert2001-10-09
| | | | | | | range of databases including MySQL, PostgreSQL, MSSQL, and others. For additional information and an 'how to upgrade', check the mails sent to the mailing list.
* - Improved db_fetch_array() to return an associative array only:Dries Buytaert2001-06-06
| | | | passing around arrays should be less expensive.
* CHANGESDries Buytaert2001-05-20
| | | | | | | | | | | | | | | | | | | | | | - Redid settings.module and even renamed it to conf.module. * Settings are now grouped in basic categories like "system settings", "module settings" and "filters". * Added new settings to make Drupal easier to configure and to make some aspects like the watchdog scale better. - Renamed includes/settings.php to includes/conf.php. - Added filter support to conf.module and introduced filter hooks so modules can implement and export new filters. Example filters are an HTML filter (implemented), a profanity filter, an url converter, ASCII smileys to images filter and so on ... - Reworked the check_* functions: user contributed content/input is only verified and filtered once in its lifespan. NOTES - Altough this is a large commit, no database changes are required.
* - added new variable: theme_footer which can be used to provide aDries Buytaert2001-04-14
| | | | | | | footer message like a copyright notice. Themes should use this! - small improvement to example theme - added theme_footer to theme marvin - small improvement to database.inc
* Last nights updates (under construction):Dries Buytaert2001-04-13
| | | | | - added _type() hook so each module can return the content types he/she implements
* - improved rating module: it now shows some basic statistics :-)Dries Buytaert2001-04-07
| | | | | | - updated database files - removed affialiate-site and drupal-site module: maintain them by hand through a box for now will you.
* Made a few cosmetic changes. Mostly just checking out how much work itKjartan Mannes2001-03-27
| | | | would be to support more databases :-)
* - applied David Norman's patch to turn all <?'s into fully qualifiedDries Buytaert2001-03-10
| | | | <?php's.
* Added "db_insert_id()", a wrapper for mysql_insert_id();Steven Wittens2001-03-03
|
* - fixed small translation glitch in format_intervalDries Buytaert2001-03-01
| | | | | | - added a couple of missing t() functions - improved the comments module, fixed the score problem Jeroen reported earlier -> it's slicker but I hope it won't break anything
* - removed redundant spacesDries Buytaert2001-01-26
|
* A batch of patches:Dries Buytaert2001-01-06
| | | | | | | | | | | | | | | | - configuration: + renamed $db_name to $db_user + renamed $db_base to $db_name - fixed small diary glitch - fixed initial-comment-score problem - fixed comment rating bug: improved the API and updated the themes - removed some tabs from Steven ;) - fixed backend warnings and improved robustness I'm not happy yet with the headline grabber - it generates too many SQL errors. - some small cosmetic changes in comment.module - fixed minor glitch in format_interval()
* - fixed bug in database.incDries Buytaert2001-01-02
|
* - here a bunch of changes to make "drupal" (for now) work with PHP 4.0.4Dries Buytaert2000-12-30
| | | | - tidied up some of the code and mainly working on the documentation
* - large batch of updatesDries Buytaert2000-12-14
|