ActiveRecord finding from inside a serialized field

Posted by JP on Stack Overflow See other posts from Stack Overflow or by JP
Published on 2010-04-16T16:42:56Z Indexed on 2010/04/16 16:53 UTC
Read the original article Hit count: 246

Filed under:
|

While working with ActiveRecord I have a table which stores a serialized array of participant usernames for each row. Is there an easy way to search for all rows who contain a specific user?

I realise I could just make a new linked table for the participants, but I feel like that would increase my overhead unnecessarily -- what do you think?

© Stack Overflow or respective owner

Related posts about ruby

Related posts about activerecord