why do you add a user_id column? thats not the way activeRecordStore
works ...

all data that you put in a session gets serialized and saved in one

when the user logs on, you would just do:

session[:user_id] =

WITHOUT having a user_id column in the sessions table. Rails handles it
for you.

don't know if you have read this article but it should answer your question