-- This file is automatically generated using maintenance/generateSchemaChangeSql.php.
-- Source: sql/abstractSchemaChanges/patch-gjlw_namespace_text.json
-- Do not modify this file directly.
-- See https://www.mediawiki.org/wiki/Manual:Schema_changes
CREATE TEMPORARY TABLE /*_*/__temp__globaljsonlinks_wiki AS
SELECT
  gjlw_id,
  gjlw_wiki
FROM /*_*/globaljsonlinks_wiki;
DROP TABLE /*_*/globaljsonlinks_wiki;


CREATE TABLE /*_*/globaljsonlinks_wiki (
    gjlw_id INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,
    gjlw_wiki BLOB NOT NULL, gjlw_namespace INTEGER DEFAULT NULL,
    gjlw_namespace_text BLOB DEFAULT NULL
  );
INSERT INTO /*_*/globaljsonlinks_wiki (gjlw_id, gjlw_wiki)
SELECT
  gjlw_id,
  gjlw_wiki
FROM
  /*_*/__temp__globaljsonlinks_wiki;
DROP TABLE /*_*/__temp__globaljsonlinks_wiki;

CREATE UNIQUE INDEX gjlw_wiki_id_namespace ON /*_*/globaljsonlinks_wiki (
    gjlw_wiki, gjlw_namespace, gjlw_namespace_text
  );
