[OWW-SC] wiki database

Austin Che austin at csail.mit.edu
Mon Jul 10 17:11:59 EDT 2006


    I don't remember who brought up the idea of user databases on the
    wiki but a request for comment was just posted to a mediawiki
    list on an extension that could be quite useful.
    
    See the demo site (look at the tutorial):
    http://www.kennel17.co.uk/testwiki/WikiDB

    If anyone has ideas for database features, it seems like we have
    someone who may actually implement those features.
    
    Here's the message from Mark Clements:
    
From: HappyDog <wikilist at ...>
Subject: Request For Comment: Wiki Database
Newsgroups: gmane.science.linguistics.wikipedia.technical
Date: 2006-07-10 12:34:40 GMT (8 hours and 33 minutes ago)
    
I have been working on the design of a wiki-style database extension to
MediaWiki.  If you can't be bothered to read the description and want to
jump right into a demo, then skip to the bottom of this mail.

WikiDB is a MediaWiki extension that adds a new type of namespace and a
couple of extra tags to the MediaWiki software.  After installing the
extension you are able to set up a table namespace in which you can define
table structures.  No table needs to be defined in order to add data to it,
and data may be located anywhere on the wiki.  This means that you can keep
record-type data inside the article it applies to, rather than being forced
to add it to a central store.  In the true 'wiki way', if you have
information to add, you can add it straight away, without requiring that a
formal structure be set up in advance.  Other people can come and refactor
your work later, once a structure is in place.

Defining a table structure adds additional functionality that allows you to
validate and format data and this structure (as with any wiki page) can be
modified at any time.  For example if you have an 'Albums' table, you can
specify, for example, that the 'year of release' field should be a date.
This will then cause all records that don't fit this definition to be
flagged up.  Change the definition to 'integer between 1850 and 2006' and it
will highlight the rows that are invalid under the new definition.  The
important thing to note is that no data is affected - when displaying any
data it is interpreted according to current the field type, so changing the
field type changes how it is _displayed_, but not how it is _stored_.

Finally, you are able to query the database for information from any table
and format it for display within any wiki page (again, no table definition
required).  Ultimately this will allow complicated queries that include join
expressions and the like, although it is currently quite (very!) basic.

This extension is at a very early (but working) stage of development, and
this is a request for comment from the MediaWiki community.  I am looking
for input at all levels - from code-optimisation to syntax to usage issues.

I have set up a demo on my testwiki (www.kennel17.co.uk/testwiki) which
gives a bit of an introduction to the extension and some details about
implementation.  I will be adding to this as I go on.  The main URL for
the extension is www.kennel17.co.uk/testwiki/WikiDB.

Please bear the following points in mind:

* The extension is in a very early stage of development. Core functionality
is in place, but many planned features are currently lacking (including some
of those mentioned above).

* The syntax is currently fairly long-winded for certain tasks. This will be
streamlined (suggestions welcome) but it is sufficient for proof-of-concept.

* There has been very little optimisation, and there is a lot of potential
for it. I welcome advice on this matter, but do not be put off by
speed/efficiency of the current version.

Thank you for reading - I look forward to your feedback.

-- 
Austin Che           <austin at csail.mit.edu>          (617)253-5899



More information about the OWW-SC mailing list