# Update problem

**URL:** <https://www.ruby-forum.com/t/update-problem/127798>\
**Category:** Rails\
**Created:** [February 1, 2008, 12:18pm UTC](https://www.ruby-forum.com/t/update-problem/127798 "2008-02-01T12:18:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ankit2584](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/51bf81/32.png) [@ankit2584](https://www.ruby-forum.com/u/ankit2584)\
**Post date:** [February 1, 2008, 12:18pm UTC](https://www.ruby-forum.com/t/update-problem/127798/1 "2008-02-01T12:18:24Z")

</div>

Hello,  
I want to update a record in the table.here r the details.

I have to modify a malinglist that contains email addresses to add  
another email in the list. But when i do  
@mailinglist.update\_attributes(params[:mailinglist])  
my old email addresses in the list are deleted and only new one remains

how can i modify the list so that i can add instead of replacing the old  
email addresses.  
Thank you.

---

<div class="post-metadata">

**Author:** ![ankit2584](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/51bf81/32.png) [@ankit2584](https://www.ruby-forum.com/u/ankit2584)\
**Post date:** [April 9, 2008, 4:47pm UTC](https://www.ruby-forum.com/t/update-problem/127798/2 "2008-04-09T16:47:37Z")

</div>

Ank Ag wrote:

> Hello,  
> I want to update a record in the table.here r the details.
> 
> I have to modify a malinglist that contains email addresses to add  
> another email in the list. But when i do  
> @mailinglist.update\_attributes(params[:mailinglist])  
> my old email addresses in the list are deleted and only new one remains
> 
> how can i modify the list so that i can add instead of replacing the old  
> email addresses.  
> Thank you.

Maybe you can try:  
@mailinglist.new(params[:mailinglist])  
@mailinglist.save
