Find ActiveRecord Session by session_id

Searching Google has given me this:
@user=CGI::Session::ActiveRecordStore::Session.find_by_session_id(@session_ id).data[:user]</code>

That would have worked pre rails 2.3

which does not work either. It throws an error saying: NameError
(uninitialized constant CGI::Session::ActiveRecordStore):

I am probably guessing that is because CGI::Session::ActiveRecordStore
is a different class than ActionController::Session::AbstractStore which
my application uses.

The corresponding active record class is now


Solved it, by using Raw SQL query to fetch the needed session object.
But decoding the base 64 encoded data gives some extra characters.