Upgrade to 2.0.2 issue re active record method missing

Greetings,

Thanks to this weekend’s BlueHost upgrade (without any notice to their
customers) to rails version 2.0.2 my application broke. Since they seem
incapable of fixing the issue, I decided to try and upgrade the
application to version 2.0.2.

In doing this, I updated all gems, etc. The webbrick server comes up
just fine and the application starts.

However, when the application attempts to update a database record, I
get the following error trace:

c:/ruby/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/attribute_methods.rb:205:in
`method_missing’

app/controllers/questionnaire_controller.rb:110:in `index’

Here is a snippet of the code referred to above at line 110 of
questionnaire_controller.rb:

108> questionnaire.session_id = session.session_id
109>
110> if questionnaire.update
111> #questionnaire update succeeded.
112> @ScreenName = “questionnaire”
113> render :action => ‘index’

114> else
115> #questionnaire update failed

Does anyone have any idea what I need to do to fix this? It appears
active record no longer likes my line: “questionnaire.update”

However, I don’t know what to change it to.

Thanks

On Feb 18, 2008 1:28 PM, Doug M. [email protected]
wrote:

Thanks to this weekend’s BlueHost upgrade (without any notice to their
customers) to rails version 2.0.2 my application broke. Since they seem
incapable of fixing the issue

All they have to do is install the version of Rails your app uses.
It’s completely possible to have multiple versions of Rails
installed.

gem list --local|grep rails
rails (2.0.2, 2.0.1, 1.2.5, 1.2.4, 1.2.3)

You also have the option of freezing your app to a specific version of
Rails.

And then at my first convenience I would move to a smarter host.


Greg D.
http://destiney.com/

Greg, thanks for the input. You can bet I’ll be looking around for
another hosting service. However, in the meantime, I’d still like to
get this application back up and running. Do you have any idea why
“questionnaire.update” would fail?

Thanks,

Doug

Greg D. wrote:

On Feb 18, 2008 1:28 PM, Doug M. [email protected]
wrote:

Thanks to this weekend’s BlueHost upgrade (without any notice to their
customers) to rails version 2.0.2 my application broke. Since they seem
incapable of fixing the issue

All they have to do is install the version of Rails your app uses.
It’s completely possible to have multiple versions of Rails
installed.

gem list --local|grep rails
rails (2.0.2, 2.0.1, 1.2.5, 1.2.4, 1.2.3)

You also have the option of freezing your app to a specific version of
Rails.

And then at my first convenience I would move to a smarter host.


Greg D.
http://destiney.com/

Here is the fix:

Assuming the code has previously set attributes in the questionnaire
object (like my code does),

change questionnaire.update to

questionnaire.update_attributes(questionnaire.attributes)