Hi,

I made one of my ID columns a string, because I don't want my IDs to
be guessable (I use a md5 hash of some system parameters with
rehashing in case of collisions.)

My migration reads:
...
change_column :users, :id, :string
change_column :comments, :user_id, :string

Afterwards executing this my db/schema.rb looks like this:
...
create_table "comments", :force => true do |t|
    t.integer  "commentable_id"
    t.string   "commentable_type"
    t.string   "user_id"
    t.datetime "date"
    t.text     "body"
end
#so far so good
...
create_table "users", :force => true do |t|
    t.string   "email"
    t.string   "pwd_hash"
    t.boolean  "is_active"
    t.datetime "last_activity"
    t.string   "pwd_salt"
    t.string   "activation_key"
    t.datetime "signup_date"
end

hmm, I consider it a bug, because running the migrations and loading
the schema from schema.rb lead to different schemas.
What do you think?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to