"ID" INTEGER NOT NULL GENERATED BY DEFAULT AS IDENTITY (START WITH 1, INCREMENT BY 1),
"NAME" VARCHAR(100) NOT NULL,
"LANGUAGE" VARCHAR(20),
- "KEE" VARCHAR(1000) NOT NULL,
- "PARENT_KEE" VARCHAR(1000),
+ "KEE" VARCHAR(255) NOT NULL,
+ "PARENT_KEE" VARCHAR(255),
"RULES_UPDATED_AT" TIMESTAMP,
"CREATED_AT" TIMESTAMP,
"UPDATED_AT" TIMESTAMP
class AddQprofileKeysColumns < ActiveRecord::Migration
def self.up
- add_column :rules_profiles, :kee, :string, :limit => 1000
- add_column :rules_profiles, :parent_kee, :string, :limit => 1000
+ add_column :rules_profiles, :kee, :string, :limit => 255
+ add_column :rules_profiles, :parent_kee, :string, :limit => 255
end
end
execute_java_migration('org.sonar.server.db.migrations.v44.FeedQProfileKeysMigration')
# set as non-null and unique
- change_column :rules_profiles, :kee, :string, :limit => 1000, :null => false
+ change_column :rules_profiles, :kee, :string, :limit => 255, :null => false
add_index :rules_profiles, :kee, :name => 'uniq_qprof_key', :unique => true
remove_column :rules_profiles, :parent_name