Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -708,6 +708,8 @@ CREATE TABLE MIN_HISTORY_WRITE_ID (
MH_WRITEID bigint NOT NULL
);

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

CREATE TABLE MIN_HISTORY_LEVEL (
MHL_TXNID bigint NOT NULL,
MHL_MIN_OPEN_TXNID bigint NOT NULL,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
ALTER TABLE HIVE_LOCKS ADD COLUMN HL_CATALOG varchar(128) NOT NULL DEFAULT 'hive';
ALTER TABLE MATERIALIZATION_REBUILD_LOCKS ADD COLUMN MRL_CAT_NAME varchar(128) NOT NULL DEFAULT 'hive';

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

-- This needs to be the last thing done. Insert any changes above this line.
UPDATE "APP".VERSION SET SCHEMA_VERSION='4.3.0', VERSION_COMMENT='Hive release version 4.3.0' where VER_ID=1;
Original file line number Diff line number Diff line change
Expand Up @@ -1207,6 +1207,8 @@ CREATE TABLE MIN_HISTORY_WRITE_ID (
MH_WRITEID bigint NOT NULL
);

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

CREATE TABLE MIN_HISTORY_LEVEL (
MHL_TXNID bigint NOT NULL,
MHL_MIN_OPEN_TXNID bigint NOT NULL,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ SELECT 'Upgrading MetaStore schema from 4.2.0 to 4.3.0' AS MESSAGE;
ALTER TABLE HIVE_LOCKS ADD HL_CATALOG nvarchar(128) NOT NULL DEFAULT 'hive';
ALTER TABLE MATERIALIZATION_REBUILD_LOCKS ADD MRL_CAT_NAME nvarchar(128) NOT NULL DEFAULT 'hive';

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

-- These lines need to be last. Insert any changes above.
UPDATE VERSION SET SCHEMA_VERSION='4.3.0', VERSION_COMMENT='Hive release version 4.3.0' where VER_ID=1;
SELECT 'Finished upgrading MetaStore schema from 4.2.0 to 4.3.0' AS MESSAGE;
Original file line number Diff line number Diff line change
Expand Up @@ -1138,6 +1138,8 @@ CREATE TABLE MIN_HISTORY_WRITE_ID (
FOREIGN KEY (MH_TXNID) REFERENCES TXNS (TXN_ID)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

CREATE TABLE MIN_HISTORY_LEVEL (
MHL_TXNID bigint NOT NULL,
MHL_MIN_OPEN_TXNID bigint NOT NULL,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ SELECT 'Upgrading MetaStore schema from 4.2.0 to 4.3.0' AS MESSAGE;
ALTER TABLE HIVE_LOCKS ADD HL_CATALOG varchar(128) NOT NULL DEFAULT 'hive';
ALTER TABLE MATERIALIZATION_REBUILD_LOCKS ADD MRL_CAT_NAME varchar(128) NOT NULL DEFAULT 'hive';

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

-- These lines need to be last. Insert any changes above.
UPDATE VERSION SET SCHEMA_VERSION='4.3.0', VERSION_COMMENT='Hive release version 4.3.0' where VER_ID=1;
SELECT 'Finished upgrading MetaStore schema from 4.2.0 to 4.3.0' AS MESSAGE;
Original file line number Diff line number Diff line change
Expand Up @@ -1126,6 +1126,8 @@ CREATE TABLE MIN_HISTORY_WRITE_ID (
MH_WRITEID NUMBER(19) NOT NULL
);

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

CREATE TABLE MIN_HISTORY_LEVEL (
MHL_TXNID NUMBER(19) NOT NULL,
MHL_MIN_OPEN_TXNID NUMBER(19) NOT NULL,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ SELECT 'Upgrading MetaStore schema from 4.2.0 to 4.3.0' AS Status from dual;
ALTER TABLE HIVE_LOCKS ADD (HL_CATALOG VARCHAR2(128) DEFAULT 'hive' NOT NULL);
ALTER TABLE MATERIALIZATION_REBUILD_LOCKS ADD (MRL_CAT_NAME VARCHAR2(128) DEFAULT 'hive' NOT NULL);

CREATE INDEX MIN_HISTORY_WRITE_ID_IDX ON MIN_HISTORY_WRITE_ID (MH_DATABASE, MH_TABLE, MH_WRITEID);

-- These lines need to be last. Insert any changes above.
UPDATE VERSION SET SCHEMA_VERSION='4.3.0', VERSION_COMMENT='Hive release version 4.3.0' where VER_ID=1;
SELECT 'Finished upgrading MetaStore schema from 4.2.0 to 4.3.0' AS Status from dual;
Original file line number Diff line number Diff line change
Expand Up @@ -1761,6 +1761,8 @@ CREATE TABLE "MIN_HISTORY_WRITE_ID" (
"MH_WRITEID" bigint NOT NULL
);

CREATE INDEX "MIN_HISTORY_WRITE_ID_IDX" ON "MIN_HISTORY_WRITE_ID" ("MH_DATABASE", "MH_TABLE", "MH_WRITEID");

CREATE TABLE "MIN_HISTORY_LEVEL" (
"MHL_TXNID" bigint NOT NULL,
"MHL_MIN_OPEN_TXNID" bigint NOT NULL,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ SELECT 'Upgrading MetaStore schema from 4.2.0 to 4.3.0';
ALTER TABLE "HIVE_LOCKS" ADD COLUMN "HL_CATALOG" varchar(128) NOT NULL DEFAULT 'hive';
ALTER TABLE "MATERIALIZATION_REBUILD_LOCKS" ADD COLUMN "MRL_CAT_NAME" varchar(128) NOT NULL DEFAULT 'hive';

CREATE INDEX "MIN_HISTORY_WRITE_ID_IDX" ON "MIN_HISTORY_WRITE_ID" ("MH_DATABASE", "MH_TABLE", "MH_WRITEID");

-- These lines need to be last. Insert any changes above.
UPDATE "VERSION" SET "SCHEMA_VERSION"='4.3.0', "VERSION_COMMENT"='Hive release version 4.3.0' where "VER_ID"=1;
SELECT 'Finished upgrading MetaStore schema from 4.2.0 to 4.3.0';
Loading