Commit graph

77 commits

Author SHA1 Message Date
Greg Sabino Mullane
770f0180c5 Fix bug 10608, plus a bonus one that was hidden by that bug. 2007-07-16 21:28:01 +00:00
Yuri Astrakhan
5a0bbe0a1a bug 10496 DISTINCT option logic incorrect in Database::makeSelectOptions 2007-07-07 21:51:06 +00:00
Tim Starling
9382bc7a85 Return a ResultWrapper from Database::query() and query builder functions, instead of a raw DB result resource. Backwards compatibility is maintained, except with naughty code that was calling database driver functions directly on result objects. 2007-07-05 19:42:18 +00:00
Aryeh Gregor
a15c419b3d Remove ?>'s from files. They're pointless, and just asking for people to mess with the files and add trailing whitespace. (Yes, I looked over every one and reverted those that were bogus. Slash-enter a million times in less worked well enough, although it was a bit mind-numbing.) 2007-06-29 01:19:14 +00:00
Greg Sabino Mullane
85ae757734 getLag() returns false, not 0. Add reminder about future code refactoring. 2007-06-22 22:00:58 +00:00
Greg Sabino Mullane
ad9595593b Return raw bytea string, not arrayified version for encodeBlob() 2007-06-22 18:45:10 +00:00
Greg Sabino Mullane
5860ba1894 Revert to correct encodeBlob() function 2007-06-11 18:40:31 +00:00
Greg Sabino Mullane
edea5f726e Fix up encodeBlob, don't worry so much about indexInfo compat. 2007-06-08 00:57:22 +00:00
Greg Sabino Mullane
dd168ed6ea Return true/false, not o/not-0 for relation checking functions, for those parts of the code that demand "result === false" rather than saying (!result) 2007-06-07 14:02:46 +00:00
Rob Church
73fda35eef (bug 10104) Provide stub "getLag()" function for DatabaseOracle and DatabasePostgres 2007-06-04 21:43:02 +00:00
Greg Sabino Mullane
277ea8a8d4 The variable mLastResult may be null /or/ false: check for both in affected rows method. 2007-05-29 20:28:59 +00:00
Greg Sabino Mullane
5b79cfb9b1 More defined() that should be isset(), thanks to David Ford, david@blue-labs.org 2007-05-16 20:31:58 +00:00
Greg Sabino Mullane
315aa73dc8 Replace defined with isset, thanks to David Ford, david@blue-labs.org 2007-05-16 20:29:05 +00:00
Greg Sabino Mullane
3658901cbe Re-add tableName call to insert, whitespace/docs cleanup. 2007-05-15 12:14:20 +00:00
Greg Sabino Mullane
9e41dca13e Redo insert() function: support IGNORE option, support multi-values.
Fixes bug #9417
2007-05-15 02:59:20 +00:00
Aaron Schulz
ccb7b43392 *Support for HAVING clause 2007-05-04 22:54:13 +00:00
Greg Sabino Mullane
6230a0863f Ignore USE INDEX option. 2007-05-02 17:35:50 +00:00
Nick Jenkins
f9619da3f0 Yet more doc tweaks:
* Add @addtogroup tags to various classes, to try and group conceptually-related classes together.
* Add brief descriptions to various Special pages, thanks to Phil Boswell.
* Moving some docs to be right above the classes they represent, so that they are picked up.
2007-04-20 08:55:14 +00:00
Greg Sabino Mullane
ba31b5beb3 Add constraintExists function, mild cleanup of other nearby funcs. 2007-04-19 01:35:15 +00:00
Aryeh Gregor
09f7aa034e "@todo no-op" sounds a bit peculiar. ;) 2007-04-18 16:37:39 +00:00
Nick Jenkins
9648f3b4d0 Some small doc tweaks to reduce Doxygen warnings, namely:
* @link. You might think @link would surely mean "here comes a web URL" ... but @link is a valid command 
  in Doxygen, which means an entirely different kind of link (an internal link to somewhere, so that you can separate 
  documentation and implementation). The result is a mess, and the best solution I can see is to use "@see" instead of "@link".
* Warning: argument `nourl' of command @param is not found in the argument list of Linker::makeMediaLinkObj($title,$text='')
* Moving few class descriptions to right above classes, and/or formatting into Javadoc style.
* "@addtogroup Special Pages" --> "@addtogroup SpecialPage" so that all special pages have the same @addtogroup tag.
* @fixme --> @todo (must have missed these before)
* "@param $specialPage @see" remove the "@" in the "@see" to stop warning.
* @throws wants type, then a brief description, to stop warning.

This last one is for PHPdocumentor only, but it fixes something for PHPDocumentor, and should be neutral for Doxygen:
* WARNING in includes/api/ApiFormatYaml_spyc.php on line 860: docblock template never terminated with /**#@-*/
2007-04-18 09:50:10 +00:00
Greg Sabino Mullane
971982db12 Add estimateRowCount(), to support changes made in r21071 2007-04-07 17:46:17 +00:00
Greg Sabino Mullane
347bf78ab6 Enforce a consistent datestyle, just in case. 2007-04-03 22:15:30 +00:00
Greg Sabino Mullane
ca5ec022ae Switch to always return GMT time. 2007-03-28 15:53:15 +00:00
Brion Vibber
4475d36182 Revert $wgDBtimezone commits: r20688, 20689, 20690, 20691.
Alters behavior of wfTimestamp() and wfTimestampNow() in clearly broken ways, such that current time would not return current time anymore.
2007-03-27 19:39:37 +00:00
Greg Sabino Mullane
72cb540911 Find out the local db timezone 2007-03-26 01:13:39 +00:00
Greg Sabino Mullane
bca55fa58f Account for pre-existing test table, commit only if setup completes. 2007-03-26 00:12:26 +00:00
Greg Sabino Mullane
3b49980821 Mild formatting, fix missing '$' 2007-03-25 23:53:36 +00:00
Greg Sabino Mullane
d6456e1e41 Remove variables when we can simply override accessors instead. 2007-03-21 18:19:35 +00:00
River Tarnell
89b14494bb - strict warning fixes in databasepostgres
- PG updaters should use general Database methods instead of reimplementing in updaters.inc
- fieldInfo should work for postgres; generalise result to an object type
- add missing *Exists() functions (rules, triggers, sequences)
2007-03-19 02:40:32 +00:00
Greg Sabino Mullane
2194fa6ed0 Typo, minor rearrangements, 2007-03-14 16:34:50 +00:00
River Tarnell
67cc9eaef3 limitResult() changes need fiddling to put options in right order 2007-03-11 15:49:27 +00:00
River Tarnell
033b6b9646 revive experimental Oracle support
fix use of limitResult(); must pass actual SQL, not empty string
2007-03-11 03:59:37 +00:00
Brion Vibber
3caa998c8c prettify:
* set_timeout() -> setTimeout()
* remove a couple obsolete references from dump code
2007-03-09 15:26:41 +00:00
River Tarnell
e8306706e8 dumpBackup should instantiate correct database class for db type
add set_timeout() method to Database
2007-03-09 02:04:36 +00:00
Leon Weber
1cda921f5a * (bug 8988) Added missing $ in error messages. 2007-02-14 16:07:18 +00:00
Greg Sabino Mullane
934d8c41e4 Add searchableIPs differentiator 2007-01-23 14:47:12 +00:00
Antoine Musso
c771fc9c96 Use Doxygen @addtogroup instead of phpdoc @package && @subpackage 2007-01-20 15:09:52 +00:00
Greg Sabino Mullane
153e82e75d Refactor versioning from setup and store number internally.
Move tsearch indexes out of tables.sql and put into setup, so 
that we can take advantage of GIN for >= 8.2
2007-01-16 04:04:55 +00:00
Greg Sabino Mullane
64b65873d5 Better checks of tsearch2 tables, schema ownership during setup. 2007-01-09 06:01:01 +00:00
Greg Sabino Mullane
765ed25069 Add implicitGroupby function to account for different database behaviors. 2007-01-02 21:34:42 +00:00
Greg Sabino Mullane
fd5115a58c Clean up some functions. 2006-12-25 22:54:01 +00:00
Greg Sabino Mullane
c576b0afa8 Add dummy selectDB function. 2006-12-25 17:25:18 +00:00
Greg Sabino Mullane
13f9951eeb Change realTimestamp to a function only, per Tim's advice. 2006-12-01 04:37:48 +00:00
Greg Sabino Mullane
5fbffc3b9e Bring reportQueryError back in sync and support the IGNORE option 2006-11-30 01:00:08 +00:00
Nick Jenkins
ae8554c45b Completing code housekeeping stuff for rest of includes/ directory: removing unused local vars, removing unused globals, replacing extract() where simple to do, declaring output arrays before calling preg_match(), and so forth. 2006-11-29 11:43:58 +00:00
Greg Sabino Mullane
38dd316259 Fix broken contribution listings with postgres by adding a new variable
to check if we are using integers or explicit timestamps.
2006-11-28 21:40:42 +00:00
Yuri Astrakhan
ccd72b22e2 forgot for prev checkin re bug 6440. Database should return all rows about a given index, not just the first. 2006-11-11 21:42:46 +00:00
Greg Sabino Mullane
d3ff4c088a Fix incorrect var name. 2006-10-31 13:31:40 +00:00
Tim Starling
3005679b0e * Removed lots of explicit require_once statements. The autoloader should theoretically be faster, because it always uses an absolute path, eliminating the need for a search, and it is never called unnecessarily. Absolute paths are also more robust in the face of odd configurations or usage patterns. Moved a few constants around to support this, they always have to be available before the method call.
* Deleted DatabaseMysql.php, no longer necessary, database classes are autoloaded. 
* Moved wfGetMimeMagic() to MimeMagic::singleton()
* Fixed a couple of __CLASS__.'::'.__FUNCTION__ things.
2006-10-03 13:00:52 +00:00