Project

General

Profile

Actions

Defect #920

closed

Welcome page fails (login problem) on new Oracle install

Added by Mark Thomas about 16 years ago. Updated over 15 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Database
Target version:
-
Start date:
2008-03-24
Due date:
% Done:

0%

Estimated time:
Resolution:
Invalid
Affected version:

Description

Rails 1.2.5 on Solaris, Oracle 10g. Brand new install of Redmine 0.6.4 (had to fix migration 85 as per revision 1069). After starting the server and attempting to browse to http://localhost:3000/ I get:

Processing WelcomeController#index (for 146.142.45.188 at 2008-03-24 15:49:19) [GET]
  Session ID: a2b8e8fa0e7083e4f825cafee9ecbbdf
  Parameters: {"action"=>"index", "controller"=>"welcome"}

ActiveRecord::StatementInvalid (OCIError: ORA-01400: cannot insert NULL into ("REACT"."USERS"."LOGIN"): INSERT INTO users (created_on, status, last_login_on, hashed_password, language, updated_on, admin, type, firstname, id, lastname, mail, auth_source_id, mail_notification, login) VALUES('2008-03-24 15:49:20', 0, NULL, '', '', '2008-03-24 15:49:20', 0, 'AnonymousUser', '', 10002, 'Anonymous', '', NULL, 0, '')):
    /labstatapps/react/vendor/rails/activerecord/lib/active_record/connection_adapters/abstract_adapter.rb:128:in `log'
    /labstatapps/react/vendor/rails/activerecord/lib/active_record/connection_adapters/oracle_adapter.rb:222:in `execute'
    /labstatapps/react/vendor/rails/activerecord/lib/active_record/connection_adapters/oracle_adapter.rb:235:in `insert'
    /labstatapps/react/vendor/rails/activerecord/lib/active_record/base.rb:1814:in `create_without_callbacks'


Related issues

Related to Redmine - Feature #944: Oracle Support in RedmineClosed2008-03-28

Actions
Actions #1

Updated by Mark Thomas about 16 years ago

I've got more information after spending a few hours trying to track this one down. Oracle treats the empty string '' as NULL in a VARCHAR2. Therefore the migrations that create a table with a :string field with :default => "" and :null => false will not work.

The migrations containing this combination are 001,007,010,013,015,017,035,042,045,046.

One solution, which may not be the best solution, is to simply remove the :null => false constraint on those fields.

Actions #2

Updated by Jean-Philippe Lang over 15 years ago

  • Category set to Database
  • Status changed from New to Closed
  • Resolution set to Invalid

Closing this ticket since Oracle DB is not supported.

Actions

Also available in: Atom PDF