No, I know.  what i'm caying is, if you *do* somehow reorder the
categories, then your objects which reference them are all re-
categorized.  that's bad - it's a dependency that is unnecessary.

On May 18, 10:15 am, Tim Shaffer <[email protected]> wrote:
> > The problem is, when you want to go back and
> > alphabetize the categories list, for example, you get the record id's
> > changing, and then an object with a category_id of 12 is now pointing
> > to a different category than it was before (since you reordered the
> > table), which forces you to create after_save actions to update all
> > the objects that reference the categories table.
>
> What? I think you might be doing it wrong. You don't need to change
> anything in the database to show the categories in alphabetical order:
>
> Category.find(:all, :order => 'title')
>
> --
> 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 
> athttp://groups.google.com/group/rubyonrails-talk?hl=en.

-- 
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