2

I've defined a scaffold with some of the sqlite columns having type double. When I run rake db:migrate, it gives the following error:

undefined method `double' for #<ActiveRecord::ConnectionAdapters::TableDefinition:>

Is there another way to specify a double that Rails will understand? Should I be using a float here?

Here's the scaffold command:

rails generate scaffold shop name:string latitude:double
nevan king
  • 112,709
  • 45
  • 203
  • 241

1 Answers1

6

Try using float instead of double. Take a look here.

Ivaylo Strandjev
  • 69,226
  • 18
  • 123
  • 176