[ https://issues.apache.org/jira/browse/HIVE-25551?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Sai Hemanth Gantasala updated HIVE-25551: ----------------------------------------- Parent: HIVE-24396 Issue Type: Sub-task (was: Bug) > Schema upgrade for MSSQL fails when adding TYPE column in DBS table > ------------------------------------------------------------------- > > Key: HIVE-25551 > URL: https://issues.apache.org/jira/browse/HIVE-25551 > Project: Hive > Issue Type: Sub-task > Reporter: Ayush Saxena > Assignee: Ayush Saxena > Priority: Major > Labels: pull-request-available > Fix For: 4.0.0, 4.0.0-alpha-1 > > Time Spent: 1h > Remaining Estimate: 0h > > The schema upgrade is failing with: > {noformat} > ALTER TABLE "DBS" ADD "TYPE" nvarchar(32) DEFAULT "NATIVE" NOT NULL; > Error: The name "NATIVE" is not permitted in this context. Valid expressions > are constants, constant expressions, and (in some contexts) variables. Column > names are not permitted. (state=S0001,code=128) > Aborting command set because "force" is false and command failed: "ALTER > TABLE "DBS" ADD "TYPE" nvarchar(32) DEFAULT "NATIVE" NOT NULL;" > [ERROR] 2021-09-23 18:34:34.917 [main] MetastoreSchemaTool - Upgrade FAILED! > Metastore state would be inconsistent !! > Upgrade FAILED! Metastore state would be inconsistent !! > [ERROR] 2021-09-23 18:34:34.917 [main] MetastoreSchemaTool - Underlying > cause: java.io.IOException : Schema script failed, errorcode OTHER > Underlying cause: java.io.IOException : Schema script failed, errorcode OTHER > [ERROR] 2021-09-23 18:34:34.917 [main] MetastoreSchemaTool - Use --verbose > for detailed stacktrace. > Use --verbose for detailed stacktrace. > [ERROR] 2021-09-23 18:34:34.917 [main] MetastoreSchemaTool - *** schemaTool > failed *** > {noformat} -- This message was sent by Atlassian Jira (v8.20.10#820010)