I'd like to second this request -
I found myself fleshing out a lot of the details of my data base
structure using categories, salutations, image_types etc tables, which
I could then populate via a scaffold, and select in other tables using
a collection select.  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.

But if categories were in an xml/yml file, then their database table
id would be irrelevant etc.


On May 18, 9:54 am, Scott Holland <[email protected]> wrote:
> Hello,
>
> I'm probably being really dumb but I can never figure this out.
>
> I want to store things like categories, salutations, image type etc etc
> but it seems dumb to create a database table for each of these.
>
> Is there any way I store this structured data in XML or YML so I can
> still call:
>
> asset.category.name etc?
>
> Thanks!
>
> Scott
> --
> Posted viahttp://www.ruby-forum.com/.
>
> --
> 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