search for: last_logged_in

Displaying 1 result from an estimated 1 matches for "last_logged_in".

2006 Feb 15
1
self in before_create
Hi, I am having a small problem concernig how to access local variables in before_create. I am not sure how to really form this question but here goes: I am wondering why this works def before_create self.last_logged_in = Time.now self.created = Time.now end but this doesn''t def before_create @last_logged_in = Time.now @created = Time.now end The latter fails with the following error: Mysql::Error: #23000Column ''last_logged_in'' cannot be null: