On 30 December 2010 13:51, Prasad B. <li...@ruby-forum.com> wrote: I am assuming that this is in response to my post, but again you have not quoted the previous message so I do not know. When replying please insert your reply into the previous message so that it is easier to follow the thread. Thanks
> i have a registration form ,i want to store data in corresponding user > table in that hobbies field > ,i want to store all hobbies in one column so i take multiple check > boxes and store in one array > all checked values for that i am using below tag,but not working,please > any suggestion > <%= check_box(:user ,:hobbies,:value =>'Games') %>Games > <%= check_box :user , :hobbies,:value =>'Music' %>Music > <%= check_box :user , :hobbies,:value => 'Shopping'%>Shopping > the above user is table name ,hobbies is column name It has already been suggested that it is not a good idea to store the hobbies all in one column. What did you learn from reading about database normalisation? Hint: You could have a hobbies table and then have a has_and_belongs_to_many association between the models. Have a look at the Rails Guide on ActiveRecord Associations if this is not familiar to you. Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.