Oracle OraNumber problem with Authentication. Please help!

I have added an authenticator using the instructions here:
http://wiki.rubyonrails.org/rails/pages/HowtoAuthenticate

The LoginController sets session[“employee”] to an employee.
When i try to access the session[“employee”] from another controller i
get this error :

"
TypeError (no marshal_dump is defined for class OraNumber):
c:/ruby/lib/ruby/1.8/pstore.rb:159:in dump' c:/ruby/lib/ruby/1.8/pstore.rb:159:in dump’
c:/ruby/lib/ruby/1.8/pstore.rb:138:in `transaction’

"

As you can tell i am using Oracle as the DB. I have added
model:employee to all the controllers that use it and to application.rb.

This is the code :

class LoginController < ApplicationController

model :employee

def authenticate
if employee = Employee.authenticate(@params[“username”],
@params[“password”])
session[“employee”] = employee
if session[“return_to”]
redirect_to_path(@session[“return_to”])
session[“return_to”] = nil
else
redirect_to :controller => “weblog”
end
else
flash[“alert”] = “Login failed!”
redirect_to :action => “index”
end
end

end

The class i access session[“employee”] from:

class TimesheetController < ApplicationController

model :employee
before_filter :authenticate

protected
def authenticate
unless session[“employee”]
session[“return_to”] = @request.request_uri
redirect_to :controller => “login”
return false
end
end

end

I am really stuck and any help would be really appreciated. I know i
could change the column types in the table from number to integer but i
am NOT allowed to do this. For now i can get by passing the employee.id
to the session, but this is not ideal.

Thanks,
Chris

I am really stuck and any help would be really appreciated. I know i
could change the column types in the table from number to integer but i
am NOT allowed to do this. For now i can get by passing the employee.id
to the session, but this is not ideal.

What version of Ruby/OCI are you using?