r47757 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r47756‎ | r47757 | r47758 >
Date:19:28, 24 February 2009
Author:ialex
Status:deferred
Tags:
Comment:
Added foreign key constraint in the PostgreSQL's schema
Modified paths:
  • /trunk/extensions/Configure/CHANGELOG (modified) (history)
  • /trunk/extensions/Configure/Configure.php (modified) (history)
  • /trunk/extensions/Configure/configure.pg.sql (modified) (history)
  • /trunk/extensions/Configure/patch-cs_id_fkey.pg.sql (added) (history)

Diff [purge]

Index: trunk/extensions/Configure/CHANGELOG
@@ -1,6 +1,11 @@
22 This file lists changes on this extension.
33 Localisation updates are done on betawiki and aren't listed here.
44
 5+0.12.5 - 24 February 2009
 6+ Added foreign key constraint in the PostgreSQL's schema.
 7+ User who used Configure.pg.sql schema in older versions can use the
 8+ patch-cs_id_fkey.pg.sql patch.
 9+
510 0.12.4 - 19 February 2009
611 Groups in $wgGroupPermissions are now sorted alphabetically.
712
Index: trunk/extensions/Configure/Configure.php
@@ -17,7 +17,7 @@
1818 'url' => 'http://www.mediawiki.org/wiki/Extension:Configure',
1919 'description' => 'Allow authorised users to configure the wiki via a web-based interface',
2020 'descriptionmsg' => 'configure-desc',
21 - 'version' => '0.12.4',
 21+ 'version' => '0.12.5',
2222 );
2323
2424 # Configuration part
Index: trunk/extensions/Configure/configure.pg.sql
@@ -33,7 +33,7 @@
3434 CREATE TABLE config_setting (
3535
3636 -- foreign key to config_version.cv_id, used for joins
37 - cs_id INTEGER NOT NULL,
 37+ cs_id INTEGER NOT NULL REFERENCES config_version( cv_id ) ON DELETE CASCADE,
3838
3939 -- setting's name
4040 cs_name TEXT NOT NULL,
@@ -42,4 +42,4 @@
4343 cs_value TEXT
4444 );
4545 ALTER TABLE config_setting ADD CONSTRAINT cs_id_name PRIMARY KEY ( cs_id, cs_name );
46 -CREATE INDEX cs_id ON config_setting( cs_id );
\ No newline at end of file
 46+CREATE INDEX cs_id ON config_setting( cs_id );
Index: trunk/extensions/Configure/patch-cs_id_fkey.pg.sql
@@ -0,0 +1,8 @@
 2+--
 3+-- Postgres' SQL schema update for Configure extension
 4+-- for people that applied configure.pg.sql in version < 0.12.5
 5+--
 6+
 7+-- Add foreign key constraint
 8+ALTER TABLE config_setting ADD CONSTRAINT config_setting_cs_id_fkey
 9+ FOREIGN KEY ( cs_id ) REFERENCES config_version( cv_id ) ON DELETE CASCADE;
Property changes on: trunk/extensions/Configure/patch-cs_id_fkey.pg.sql
___________________________________________________________________
Name: svn:eol-style
110 + native

Status & tagging log