Evan Prodromou wrote:
Why did we write our own database abstraction layer
when there's one
already in PEAR?
Database abstraction is only a small part of what Database.php does.
PEAR has a couple of query-building functions -- a quoting function, for
instance. Our query-building functions are much better. Maybe we should
contribute what we have done to PEAR at some stage.
An interface to PEAR's DB module, or PHP's native dbx module, was in
fact the next Database subclass I wanted to write. It would be handy for
non-Wikimedia users.
You should think of Database.php as a query-building module rather than
a DB abstraction layer.
-- Tim Starling