Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
私は次のクラスを持っています
class Foo < ActiveRecord::Base serialize: bar end
花のリストが含まれているはずです(ユリ、ジャスミンなど)。この情報を保存するには、どの形式を使用すればよいですか
配列
Foo.new.bar = %w(lilly jasmine)
または、YAML を介してシリアル化できる任意の種類のオブジェクトについては、こちらをご覧ください