Ray Ray wrote in post #956181:
> Colin Law wrote in post #956170:
>>
>> Note that it is not a good idea to rely on the id of a record having a
>> particular value (1 in this case).  If you want a field containing a
>> meaningful number then add another field to contain that number.
>>
>> Colin
>
> Ok, but my idea behind is that i only use this one value. Then i have
> the option to edit/update it, so there's always one value according to
> ID 1. No create/delete options available.

Then that's a bad idea.  Colin is absolutely right: no particular ID 
value should ever, ever, ever be meaningful.

>
> Well asides that, i have another problem. I want to associate 2 models:
> country and events (with country has many events and event belongs to
> country). I use both in the countries_controller, but i dont know how to
> create objects in events thorugh this controller. You got any
> suggestions?

Have you read the Associations guide yet?

>
> Thanks for your interest, so far.

Best,
--
Marnen Laibow-Koser
http://www.marnen.org
[email protected]

-- 
Posted via http://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 at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to