Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-24396 [New Feature] Add data connector support for remote datasources
  3. HIVE-25551

Schema upgrade for MSSQL fails when adding TYPE column in DBS table

    XMLWordPrintableJSON

Details

    Description

      The schema upgrade is failing with:

            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 ***
      

      Attachments

        Issue Links

          Activity

            People

              ayushtkn Ayush Saxena
              ayushtkn Ayush Saxena
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h
                  1h