Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6031023
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T05:07:23+00:00 2026-05-23T05:07:23+00:00

My Environment -> Ruby 1.9.2 and Rails v3.0.5 I noted a strange pattern in

  • 0

My Environment -> Ruby 1.9.2 and Rails v3.0.5

I noted a strange pattern in rake db:reset. According to rails source code, rake db:reset will => db:drop, db:create and db:migrate. https://github.com/rails/rails/blob/v3.0.5/activerecord/lib/active_record/railties/databases.rake#L159

Setup: One of my migration files have Model.create statements to populate some data (Forgive me, I’m not the one who had put data-filling-code in those migrations 🙂 ..)

Case 1: When I do the steps manually, i mean drop, create, and migrate, one by one – those statements fill data in the table.

Case 2: When I do just rake db:reset, schema is set properly. but the data is not entering the db. Does db:reset skip create/update statements.. I have tried this several times to make sure that I have no faults in the steps I do. I still get this behavior.

what is going wrong here… ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T05:07:23+00:00Added an answer on May 23, 2026 at 5:07 am

    I think you’re reading the wrong line in the source. As I read it:

    db:migrate:reset # => [:drop, :create, :migrate]

    db:reset # => [:drop, :setup]

    So db:reset just create the tables and sets the migrations as if they had been run, without actually running them. db:migrate:reset actually runs each migration.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

On a Ruby on Rails development environment, a page will be shown after 30
we have a mixed development environment using ASP.NET MVC and Ruby on Rails. We
My development environment: Ubuntu 9 Ruby 1.9.1/1.8.7 (rvm) Rails 2.3.5 Mysql 5.0 Apache Passenger
how to make the ruby on rails with mysql environment in ubuntu 11.04. I
My environment: Ruby 1.9.2p290, Rails 3.0.9 and RubyGem 1.8.8 unfortunately I have an issue
Environment: Ruby 1.9.2, Rails 3.0.3, Ubuntu When I try to open a URL using:
Context: I am trying to practice BDD in a Ruby on Rails environment using
I am using Ruby On Rails 2.3.5 with haml version 2.2.21 (in my environment.rb
I want to learn Ruby on Rails and have set up a test environment.
So I'm working on one computer with some ruby/rails code and its working fine.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.