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

  • Home
  • SEARCH
  • 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 363763
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T13:22:25+00:00 2026-05-12T13:22:25+00:00

There are about a hundred or so migrations in my migrate folder with numeric

  • 0

There are about a hundred or so migrations in my migrate folder with numeric prefixes, then about a hundred or so with timestamp prefixes, so i guess at some point Rails version was updated. Now I want to go stop Rails from using timestamp prefixes as i prefer numeric prefixes. What is the best way to accomplish this, or is this even possible? One approach may be to manually rename the prefixes in their sort order, and then go to dev, staging and production databases and change the timestamps by the new numbers, but this approach looks messy. is there some other way to accomplish this?

  • 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-12T13:22:25+00:00Added an answer on May 12, 2026 at 1:22 pm

    Timestamped migrations are awesome if you have a team, or if you want to branch and work on something else. However you can change how migrations are named with a config setting.

    #environment.rb
    config.active_record.timestamped_migrations = false
    

    Also…. the lazy_developer plugin I maintain has a task to transform all of your migration files into a brand-new migration. I make no warranties that it will work for you, but I’ve used it on a few projects to get things where i want them to be.

    http://github.com/napcs/lazy_developer

    It basically takes schema.rb and makes a new migration from it. It tries to handle your indexes too, but it does use a timestamp for the migration number, setting the new migration it creates to the same name as the last migration so that your database’s versioning is correctly maintained.

    Again, no guarantee this will work, so backup or branch your project first!

    If I were you, I’d leave this alone. It’s convention to have the migration names, and really, you only have to use them at most once. If you’re deploying to a new server or checking the project out to a new machine, you should really use rake db:schema:load instead as it’s much faster. Migrations are meant for development and incremental db changes. And like I said, timestamped migrations rock for multiple users.

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

Sidebar

Ask A Question

Stats

  • Questions 190k
  • Answers 190k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer I think the benefits of using OpenID are pretty well… May 12, 2026 at 5:56 pm
  • Editorial Team
    Editorial Team added an answer It is indeed a pain: you need a NavigationWindow that… May 12, 2026 at 5:56 pm
  • Editorial Team
    Editorial Team added an answer Speaking for C# generally (not mono specifically): it makes no… May 12, 2026 at 5:56 pm

Related Questions

I have 5 databases which represent different regions of the country. In each database,
I'm trying to track down the bottleneck in an IPhone OpenGL game I'm writing.
I'm trying to use this tool https://swingexplorer.dev.java.net/ to find some information out about an
Wrote a small app that accesses a bunch of search websites and puts the

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.