Ruby on rails migration problem

Hello all,

I have created a migration add_details _to users ... ( city_id ,
profession )
and then migrated it..

when i use params[:user] to update the database by taking user inputs
from forms in views, it is not updating the database for these city_id
and profession... ( not changing from null )
if add validation for presence of city_id .. it is giving the error
"City id cant be blank." even though i filled it...

where as it is working fine with the fields i have added in
create_users migration...

do i have to change anything else when create new migration in
AddDetailstoUsers migration .. other than using rake db:migrate ....


use add_detail_to_users

or if you ran the migration properly - maybe it's a mass assignment

if you have attr_accessible in your model and you haven't added these
new attributes to be accessible then you would be getting these

Thank you so much..
This solved my problem ... :slight_smile: