sankarh commented on code in PR #4450:
URL: https://github.com/apache/hive/pull/4450#discussion_r1278255281


##########
standalone-metastore/src/main/sql/postgres/hive-schema-3.1.0.postgres.sql:
##########
@@ -171,7 +171,8 @@ CREATE TABLE "PARTITIONS" (
     "LAST_ACCESS_TIME" bigint NOT NULL,
     "PART_NAME" character varying(767) DEFAULT NULL::character varying,
     "SD_ID" bigint,
-    "TBL_ID" bigint
+    "TBL_ID" bigint,
+    "WRITE_ID" bigint DEFAULT 0

Review Comment:
   Add WRITE_ID column in hive-schema-3.2.0.*.sql files only.



##########
standalone-metastore/src/main/sql/postgres/upgrade-3.0.0-to-3.1.0.postgres.sql:
##########
@@ -51,6 +51,11 @@ CREATE TABLE MATERIALIZATION_REBUILD_LOCKS (
   PRIMARY KEY(MRL_TXN_ID)
 );
 
+-- HIVE-19416
+ALTER TABLE "TBLS" ADD COLUMN "WRITE_ID" bigint DEFAULT 0;

Review Comment:
   Add this change only in upgrade-3.1.0-to-3.2.0.*.sql file only. If this file 
doesn't exist, then create one.



##########
standalone-metastore/src/main/sql/oracle/upgrade-3.1.0-to-3.2.0.oracle.sql:
##########
@@ -28,7 +28,6 @@ UPDATE PARTITION_PARAMS SET TEMP=PARAM_VALUE, 
PARAM_VALUE=NULL;
 ALTER TABLE PARTITION_PARAMS DROP COLUMN PARAM_VALUE;
 ALTER TABLE PARTITION_PARAMS RENAME COLUMN TEMP TO PARAM_VALUE;
 
-
 -- These lines need to be last.  Insert any changes above.
 UPDATE VERSION SET SCHEMA_VERSION='3.2.0', VERSION_COMMENT='Hive release 
version 3.2.0' where VER_ID=1;

Review Comment:
   How come 3.1.0-to-3.2.0 file exist for Oracle but not for Postgres?



##########
standalone-metastore/src/main/sql/postgres/hive-schema-3.1.0.postgres.sql:
##########
@@ -395,7 +396,8 @@ CREATE TABLE "TBLS" (
     "TBL_TYPE" character varying(128) DEFAULT NULL::character varying,
     "VIEW_EXPANDED_TEXT" text,
     "VIEW_ORIGINAL_TEXT" text,
-    "IS_REWRITE_ENABLED" boolean NOT NULL DEFAULT false
+    "IS_REWRITE_ENABLED" boolean NOT NULL DEFAULT false,
+    "WRITE_ID" bigint DEFAULT 0

Review Comment:
   Same as above comment.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to