Forum: Ruby on Rails Serialize

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
27fe920a741edb3d3824a0495acff070?d=identicon&s=25 Bruno A. (beer)
on 2006-01-24 20:32
HI all,

I not understand a method serialize.
Anyone have any example using de serialize.....

Bill Katz (Guest)
on 2006-01-24 20:52
(Received via mailing list)
>From the most excellent "Agile Web Development with Rails" book, p. 206:

class Purchase < ActiveRecord::Base
  serialize :last_five
  # ...

purchase =
purchase.last_five = [ 'shoes', 'shirt', 'socks', 'ski mask', 'shorts' ]
This topic is locked and can not be replied to.