Defect #5335
closedError on db:migrate with table prefix set (hardcoded name in principal.rb)
0%
Description
Principal.rb has hardcoded table name on first line (set_table_name 'users'). This error prevents the use of table_name_prefix (config.active_record.table_name_prefix).
Error:
AddUserPreferencesTimeZone: migrating ===================================
-- add_column(:user_preferences, :time_zone, :string)
-> 0.0041s
AddUserPreferencesTimeZone: migrated (0.0042s) ==========================
-- add_column(:users, :type, :string)
-> 0.0048s
rake aborted!
An error has occurred, all later migrations canceled:
Mysql::Error: Table 'redmine.users' doesn't exist: SHOW FIELDS FROM `users`
Application's environment:
Ruby version 1.8.7 (i686-linux)
RubyGems version 1.3.5
Rack version 1.0
Rails version 2.3.5
Active Record version 2.3.5
Active Resource version 2.3.5
Action Mailer version 2.3.5
Active Support version 2.3.5
Edge Rails revision unknown
Application root /var/lib/redmine
Environment production
Database adapter mysql
Database schema version 0
Updated by Jean-Philippe Lang over 14 years ago
- Status changed from New to Resolved
- Target version set to 0.9.4
- Resolution set to Fixed
Fixed in r3678.
Updated by Jean-Philippe Lang over 14 years ago
- Status changed from Resolved to Closed