X-Git-Url: https://scripts.mit.edu/gitweb/autoinstallsdev/mediawiki.git/blobdiff_plain/19e297c21b10b1b8a3acad5e73fc71dcb35db44a..6932310fd58ebef145fa01eb76edf7150284d8ea:/maintenance/postgres/archives/patch-add_interwiki.sql

diff --git a/maintenance/postgres/archives/patch-add_interwiki.sql b/maintenance/postgres/archives/patch-add_interwiki.sql
new file mode 100644
index 00000000..6c08af7a
--- /dev/null
+++ b/maintenance/postgres/archives/patch-add_interwiki.sql
@@ -0,0 +1,14 @@
+DROP FUNCTION IF EXISTS add_interwiki(TEXT,INT,CHARACTER) CASCADE;
+CREATE OR REPLACE FUNCTION "add_interwiki" (TEXT,INT,SMALLINT) RETURNS INT LANGUAGE SQL AS
+$mw$
+  INSERT INTO interwiki (iw_prefix, iw_url, iw_local) VALUES ($1,$2,$3);
+  SELECT 1;
+$mw$;
+
+DROP FUNCTION IF EXISTS add_interwiki(TEXT,INT,CHARACTER) CASCADE;
+CREATE OR REPLACE FUNCTION "add_interwiki" (TEXT,INT,SMALLINT) RETURNS INT LANGUAGE SQL AS
+$mw$
+  INSERT INTO interwiki (iw_prefix, iw_url, iw_local) VALUES ($1,$2,$3);
+  SELECT 1;
+$mw$;
+
