rails 数据类型对比 mysql postgresql sqlite


Rails mysql postgresql sqlite
binary blob bytea blob
boolean tinyint(1) boolean boolean
date date date date
datetime datetime timestamp datetime
decimal decimal decimal decimal
float float float float
integer int(11)  integer integer
string varchar(255)  * varchar(255)
text text text text
time time time datetime
timestamp datetime timestamp datetime

 

你可能感兴趣的:(ruby on rails)