我在Heroku上运行了一些迁移,我遇到了这个问题.我在其中一个迁移中有这一行来创建一个新表:
t.binary :file,:limit => 10.megabytes
An error has occurred,this and all later migrations canceled: PGError: ERROR: type modifier is not allowed for type "bytea" LINE 1: ..."file" bytea(10485760)... ^ : CREATE TABLE "files" ("id" serial primary key,"file" bytea(10485760),"created_at" timestamp,"updated_at" timestamp)
如何更改我的迁移,以便它与MysqL和Postgre一起使用?