rails migration. modify starting point for auto_increment

Posted by railsnew on Stack Overflow See other posts from Stack Overflow or by railsnew
Published on 2010-04-25T23:49:14Z Indexed on 2010/04/25 23:53 UTC
Read the original article Hit count: 213

Filed under:
|
|

I have a table already created. I am looking for a rails migration where I can modify the starting point of the auto_increment number for id column of my table. Let's say I want it to start from 1000.

I googled a bit and came across this:

it says:

:options "string" pass raw options to your underlying database, e.g. auto_increment = 10000. Note that passing options will cause you to lose the default ENGINE=InnoDB statement

Can this be used for something I want? and how will the migration look since i am changing the column and not creating new one...

© Stack Overflow or respective owner

Related posts about rails

Related posts about migration