将声纳更新到4.1.2无法升级DB

时间:2014-07-08 23:08:33

标签: oracle10g sonarqube

我使用Oracle 10.2从Sonar 3.4.1升级到4.1.2

我已根据目标版本支持的版本更新了所有插件。

单击/ setup页面中的Upgrade按钮后出现此错误:

2014.07.08 19:15:06 INFO  [DbMigration]
2014.07.08 19:15:06 INFO  [DbMigration]  ==  AddNetworkUseSubCharacteristic: migrating =============================                                                                                                                          ====
2014.07.08 19:15:06 ERROR [o.s.s.ui.JRubyFacade]  Fail to upgrade database
An error has occurred, all later migrations canceled:

ActiveRecord::JDBCError: ORA-00904: "DESCRIPTION": invalid identifier
: INSERT INTO characteristics (kee, name, rule_id, characteristic_order, enabled, parent_id, root_id, function_key,                                                                                                                           factor_value, factor_unit, offset_value, offset_unit, created_at, updated_at, quality_model_id, depth, description,                                                                                                                           id) VALUES('NETWORK_USE_EFFICIENCY', 'Network use', NULL, NULL, 1, 10347, 10347, NULL, NULL, NULL, NULL, NULL, TO_TI                                                                                                                          MESTAMP('2014-07-08 19:15:06:825000','YYYY-MM-DD HH24:MI:SS:FF6'), TO_TIMESTAMP('2014-07-08 19:15:06:825000','YYYY-M                                                                                                                          M-DD HH24:MI:SS:FF6'), NULL, NULL, NULL, ?)
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstrac                                                                                                                          t_adapter.rb:227:in `log'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstrac                                                                                                                          t_adapter.rb:212:in `log'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-jdbc-adapter-1.1.3/lib/arjdbc/oracle/adapter.rb:183:                                                                                                                          in `ora_insert'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstrac                                                                                                                          t/query_cache.rb:26:in `insert_with_query_dirty'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/base.rb:2967:in `create'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/timestamp.rb:53:in `create_                                                                                                                          with_timestamps'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/callbacks.rb:266:in `create                                                                                                                          _with_callbacks'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/base.rb:2933:in `create_or_                                                                                                                          update'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/callbacks.rb:250:in `create                                                                                                                          _or_update_with_callbacks'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/base.rb:2583:in `save'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/validations.rb:1089:in `sav                                                                                                                          e_with_validation'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/dirty.rb:79:in `save_with_d                                                                                                                          irty'
        org/jruby/RubyKernel.java:2225:in `send'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/transactions.rb:229:in `wit                                                                                                                          h_transaction_returning_status'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstrac                                                                                                                          t/database_statements.rb:136:in `transaction'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/transactions.rb:182:in `tra                                                                                                                          nsaction'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/transactions.rb:228:in `wit                                                                                                                          h_transaction_returning_status'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/transactions.rb:196:in `sav                                                                                                                          e_with_transactions'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/transactions.rb:208:in `rol                                                                                                                          lback_active_record_state!'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/transactions.rb:196:in `sav                                                                                                                          e_with_transactions'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/base.rb:727:in `create'
        /opt/sonarqube-4.1.2/web/WEB-INF/db/migrate/466_add_network_use_sub_characteristic.rb:42:in `up'
        org/jruby/RubyKernel.java:2221:in `send'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:282:in `migrat                                                                                                                          e'
        jar:file:/opt/sonarqube-4.1.2/web/WEB-INF/lib/jruby-complete-1.7.6.jar!/META-INF/jruby.home/lib/ruby/1.8/ben                                                                                                                          chmark.rb:293:in `measure'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:282:in `migrat                                                                                                                          e'
        org/jruby/RubyKernel.java:2225:in `send'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:365:in `migrat                                                                                                                          e'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:491:in `migrat                                                                                                                          e'
        org/jruby/RubyProc.java:290:in `call'
        org/jruby/RubyProc.java:224:in `call'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:567:in `ddl_tr                                                                                                                          ansaction'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:490:in `migrat                                                                                                                          e'
        org/jruby/RubyArray.java:1613:in `each'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:477:in `migrat                                                                                                                          e'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:401:in `up'
        /opt/sonarqube-4.1.2/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/migration.rb:383:in `migrat                                                                                                                          e'
        /opt/sonarqube-4.1.2/web/WEB-INF/lib/database_version.rb:62:in `upgrade_and_start'
        /opt/sonarqube-4.1.2/web/WEB-INF/app/models/database_migration_manager.rb:109:in `start_migration'
        org/jruby/RubyProc.java:290:in `call'
        org/jruby/RubyProc.java:228:in `call'

不确定为什么会出现与无效标识符相关的错误。 在此先感谢您的帮助。

CHARACTERISTICS表结构:

{  名字空?型


ID NOT NULL NUMBER(38)  KEE VARCHAR2(100)  NAME VARCHAR2(100)  RULE_ID号码(38)  CHARACTERISTIC_ORDER NUMBER(38)  已启用的号码(1)  PARENT_ID号码(38)  ROOT_ID号码(38)  FUNCTION_KEY VARCHAR2(100)  FACTOR_VALUE NUMBER(30,20)  FACTOR_UNIT VARCHAR2(100)  OFFSET_VALUE NUMBER(30,20)  OFFSET_UNIT VARCHAR2(100)  CREATED_AT TIMESTAMP(6)  UPDATED_AT TIMESTAMP(6) }

0 个答案:

没有答案