So I am a new comer to ROR and Heroku and need some help. I have produced an application and also have used it however, Let me obvious the database connected by using it. Meaning Let me obvious any customers (as well as their attached data) which have been produced so far.
I have essentially produced several phony accounts to try out if the database around the production site works, however let me obvious this out, and begin having a fresh database.
Is possible without removing the database entirely?
Any help could be sincerely appreciated. Thanks greatly for the time!
You should use
heroku pg:reset --db SHARED_DATABASE_URL command to totally reset the whole database. The command only will drop and make the database.
Make use of heroku
rake db:migrate to produce the tables then.
Alternatively you should use
rake db:reset command in your area after which run
heroku db:push to update the development db.
Yes, you may either use SQL techniques to get it done or possibly only use the Rails Console to get it done in the command line and call the @customers.destroy_all method. This article describes ways to use the console from Heroku.