I have an \'Account\' model in Rails with its corresponding \'accounts\' table in the database. If I wipe the database and start over, the \'account_id\' field will always star
Another possible concept might be to simply use a start_at variable in your model file?
Such as define a base number such as start_at = 53131
and then...
Make an accessor method (could call it "key") which adds your start_at
number to your database's real ID before returning it.
And you could make a attr writer method that subtracts the start_at
before saving the key, that may not even be necessary depending on your implementation.
Example in pseudo-code so bear with me.
class FakeModel
attr_accessible :name
start_at = 53121
def self.find_by_key(key)
find_by_id(key-start_at))
end
def key
(self.id+start_at)
end
end
Not sure how practical this is or if it would even work 100% but at least you wouldn't have to modify the database to handle it.