Update column value


Is there any way that I can Update column value of another table when
saving form data of another model.

For example:

I have two models model A and model B. Both of them have one to many
relation with each other.

On filling data in form fields of model B , when particular condition
met, i want to update the column value of model A.

Both model A and model B have a one-to-many relationship. Seems to me that you have not done your homework.

There is a huge abundance of information on the web to understand Ruby and Ruby on Rails. Research: Rails models associations


As I explained when you first asked this problem you can write to
records in any table you like in any controller. Simple find the
record you want, update the value and save it. I note you did not
reply to the help offered by Elizabeth or myself in that case.

Also, as Elizabeth suggested, I think perhaps you have missed some of
the basic concepts of Rails and suggest that working right through a
good tutorial such as railstutorial.org (which is free to use online)
would help you and save you a lot of time in the long run.