This is my first post here, so it's easy. I am trying to create my first application in Rails 3.2.1. I am trying to create a scaffold for Paint using the following terminal command:
rails generate scaffold Paint paint_family:string paint_hex:array paint_available:boolean paint_location:integer paint_quantity:integer paint_additional_info:text
But when I try to migrate, I get the following error:
undefined method `array' for #<ActiveRecord::ConnectionAdapters::TableDefinition:0x007fbd8bdb1c58>
Here is the migration entry:
class CreatePaints < ActiveRecord::Migration def change create_table :paints do |t| t.string :paint_family t.array :paint_hex t.boolean :paint_available t.integer :paint_location t.integer :paint_quantity t.text :paint_additional_info t.timestamps end end
end
I canβt understand for life why this is so. But this is because I do not know what I am doing. Any advice / help would be greatly appreciated.
source share