I'm trying to run db:migrate. This fails however because one of the tables that one of the migrations is trying to update does not exist. I searched the codebase and this table is created in db/schema.rb.
How can I run schema.rb before db:migrate??
Use the schema load task:
rake db:schema:load
From rake -T
(expurgated version):
rake db:schema:dump # Create db/schema.rb file usable with any AR-supported DB
rake db:schema:load # Load schema.rb file into DB
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.