jenkins-bot has submitted this change and it was merged.

Change subject: Add support for sqlite
......................................................................


Add support for sqlite

* Missing sqlite support in localdb_patches folder.

Bug: T69300
Change-Id: I3c697e31e486dca43a0733a45aab6d72861801fc
---
M globalblocking.sql
M localdb_patches/setup-global_block_whitelist.sql
2 files changed, 14 insertions(+), 13 deletions(-)

Approvals:
  Aaron Schulz: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/globalblocking.sql b/globalblocking.sql
index 7c9a7a1..00e6bcf 100644
--- a/globalblocking.sql
+++ b/globalblocking.sql
@@ -1,4 +1,4 @@
-CREATE TABLE /*$wgDBprefix*/globalblocks (
+CREATE TABLE /*_*/globalblocks (
        gb_id int NOT NULL PRIMARY KEY AUTO_INCREMENT,
        gb_address varchar(255) NOT NULL,
        gb_by varchar(255) NOT NULL,
@@ -11,12 +11,12 @@
        gb_range_end varbinary(35) NOT NULL
 ) /*$wgDBTableOptions*/;
 
-CREATE UNIQUE INDEX gb_address ON /*$wgDBprefix*/globalblocks (gb_address, 
gb_anon_only);
-CREATE INDEX gb_range ON /*$wgDBprefix*/globalblocks (gb_range_start, 
gb_range_end);
-CREATE INDEX gb_timestamp ON /*$wgDBprefix*/globalblocks (gb_timestamp);
-CREATE INDEX gb_expiry ON /*$wgDBprefix*/globalblocks (gb_expiry);
+CREATE UNIQUE INDEX /*i*/gb_address ON /*_*/globalblocks (gb_address, 
gb_anon_only);
+CREATE INDEX /*i*/gb_range ON /*_*/globalblocks (gb_range_start, gb_range_end);
+CREATE INDEX /*i*/gb_timestamp ON /*_*/globalblocks (gb_timestamp);
+CREATE INDEX /*i*/gb_expiry ON /*_*/globalblocks (gb_expiry);
 
-CREATE TABLE /*$wgDBprefix*/global_block_whitelist (
+CREATE TABLE /*_*/global_block_whitelist (
        gbw_id int(11) NOT NULL PRIMARY KEY, -- Key to gb_id in globalblocks 
database.
        gbw_address varbinary(255) NOT NULL,
        gbw_by int(11) NOT NULL, -- Key to user_id
@@ -24,4 +24,5 @@
        gbw_reason varchar(255) NOT NULL,
        gbw_expiry binary(14) NOT NULL
 ) /*$wgDBTableOptions*/;
-CREATE INDEX gbw_by ON /*$wgDBprefix*/global_block_whitelist (gbw_by);
\ No newline at end of file
+
+CREATE INDEX /*i*/gbw_by ON  /*_*/global_block_whitelist (gbw_by);
\ No newline at end of file
diff --git a/localdb_patches/setup-global_block_whitelist.sql 
b/localdb_patches/setup-global_block_whitelist.sql
index 23a4a76..280daea 100644
--- a/localdb_patches/setup-global_block_whitelist.sql
+++ b/localdb_patches/setup-global_block_whitelist.sql
@@ -1,13 +1,13 @@
 -- Patch to create local table for whitelisted global blocks
 -- Andrew Garrett, April 2008
 
-CREATE TABLE /*$wgDBprefix*/global_block_whitelist (
-       gbw_id  int(11) NOT NULL, -- Key to gb_id in globalblocks database.
+CREATE TABLE /*_*/global_block_whitelist (
+       gbw_id int(11) NOT NULL PRIMARY KEY, -- Key to gb_id in globalblocks 
database.
        gbw_address varbinary(255) NOT NULL,
        gbw_by  int(11) NOT NULL, -- Key to user_id
        gbw_by_text varchar(255) NOT NULL,
        gbw_reason varchar(255) NOT NULL,
-       gbw_expiry binary(14) NOT NULL,
-       PRIMARY KEY (gbw_id),
-       KEY (gbw_by)
-) /*$wgDBTableOptions*/;
\ No newline at end of file
+       gbw_expiry binary(14) NOT NULL
+) /*$wgDBTableOptions*/;
+
+CREATE INDEX /*i*/gbw_by ON  /*_*/global_block_whitelist (gbw_by);
\ No newline at end of file

-- 
To view, visit https://gerrit.wikimedia.org/r/189354
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3c697e31e486dca43a0733a45aab6d72861801fc
Gerrit-PatchSet: 7
Gerrit-Project: mediawiki/extensions/GlobalBlocking
Gerrit-Branch: master
Gerrit-Owner: Paladox <[email protected]>
Gerrit-Reviewer: Aaron Schulz <[email protected]>
Gerrit-Reviewer: Bartosz DziewoƄski <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: MaxSem <[email protected]>
Gerrit-Reviewer: Paladox <[email protected]>
Gerrit-Reviewer: Reedy <[email protected]>
Gerrit-Reviewer: Siebrand <[email protected]>
Gerrit-Reviewer: Springle <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to