Topic: devise - jdbc error
Hi!
I'm fairly new to rails and I can't detect the source of the problem.
I installed devise via the Installation Guide and if I try to "Sign up" , there is the following error:
(I also added an username-field but the problem stayed the same.)
ActiveRecord::StatementInvalid in Devise::RegistrationsController#create
ActiveRecord::JDBCError: Bei der Konvertierung eines varchar-Datentyps in einen datetime-Datentyp liegt der Wert außerhalb des gültigen Bereichs.: INSERT INTO [users] ([created_at], [current_sign_in_at], [current_sign_in_ip], , [encrypted_password], [last_sign_in_at], [last_sign_in_ip], [remember_created_at], [reset_password_sent_at], [reset_password_token], [sign_in_count], [updated_at], [username]) VALUES ('2012-01-16 06:59:50', NULL, NULL, N'test@test.de', N'$2a$10$zz5ePfGa4bFRUjO7bemhhO7Mv/ll.myvDxPMnSzejQN9/BsaI4f0K', NULL, NULL, NULL, NULL, NULL, 0, '2012-01-16 06:59:50', N'test')
(Couldn't post without "[/ email]" but this isn't in the error message of course)
Theres a problem with the conversion from a varchar-type to a datetime-type .
This is my migration (default devise 1.5.3)
class DeviseCreateUsers < ActiveRecord::Migration
def change
create_table(:users) do |t|
t.database_authenticatable :null => false
t.recoverable
t.rememberable
t.trackable
# t.encryptable
# t.confirmable
# t.lockable :lock_strategy => :failed_attempts, :unlock_strategy => :both
# t.token_authenticatable
t.timestamps
end
add_index :users, :email, :unique => true
add_index :users, :reset_password_token, :unique => true
# add_index :users, :confirmation_token, :unique => true
# add_index :users, :unlock_token, :unique => true
# add_index :users, :authentication_token, :unique => true
end
end
Last edited by taliking (2012-01-16 03:21:39)