ruby-on-railsdatabaseherokutaps

Heroku db:pull taps gem pulls previously db:push'd data instead of current data


I'm using the taps gem, and I am trying to use heroku db:pull to pull down my current production database.

However, when I pull, it pulls down a database that I db:push'd almost 3 months ago, instead of the current DB.

Is there a way to specify that I want the latest? Is it possible to remove that old database?

Thanks for your time

EDIT: I'm using MySQL locally, and I am aware of pgbackups and am trying to avoid the pg dumping associated with that.


Solution

  • If you have multiple deployment environments (ie staging vs production), make sure you specify the right one with db:pull --app productionAppName.

    If you have unused tables in the production environment that you want to get rid of, your two options are:

    1. create a migration to drop the table
    2. "heroku run rails console" and manually drop the tables.

    both techniques are described in this post: Heroku Drop Table Rails Help

    hope it helps!