What is the difference between Rails data types?

I know that Rails data types can be found here:

Rails 4: List of Available Data Types

or here:

http://api.rubyonrails.org/classes/ActiveRecord/ConnectionAdapters/TableDefinition.html#method-i-column

but what I can’t find is a clear definition of each, as well as the differences between, say, a float or decimal, or string compared to text.

Where can I find detailed definitions of data types?

+4
source share
2 answers

Here's a nice set of definitions (from fooobar.com/questions/21411 / ... )

  • binary - for storing data such as images, audio or movies.
  • boolean - .
  • date -
  • datetime - .
  • decimal - .
  • float - . ( ?)
  • integer - .
  • primary_key - , .
  • string - , . ( ?)
  • - , .
  • -
  • timestamp - .
+6

All Articles