[
https://issues.apache.org/jira/browse/HIVE-25551?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Naveen Gangam resolved HIVE-25551.
----------------------------------
Fix Version/s: 4.0.0
Resolution: Fixed
Fix has been pushed to master. Closing the jira. Thanks for the patch
[~ayushtkn]
> 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: Bug
> Reporter: Ayush Saxena
> Assignee: Ayush Saxena
> Priority: Major
> Labels: pull-request-available
> Fix For: 4.0.0
>
> Time Spent: 0.5h
> 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.3.4#803005)