On Sat, Sep 24, 2016 at 12:01 PM, Richard McSharry
wrote:
**Example 1 - one-to-one**
> ```ruby
> class Employee
> has_one :salary
> end
> class Salary
> has_key_for :employee
> end
> ```
>
Generally speaking, the Active Record API expresses stuff at the entity
level, at
Sequel gem (which i had used for supporting legacy databases) is clearer to
me. But i still can work on both ActiveRecord and Sequel-type associations.
https://github.com/jeremyevans/sequel#associations
On Sat, Sep 24, 2016 at 10:42 PM, Chad Woolley
wrote:
> I agree.
I agree. I've been doing Rails for 10 years (and databases for going on
25)), and "belongs_to" has always been a cognitive blocker for me.
I wouldn't do away with "belongs_to", but making "has_key_for" aliases
sounds like a great idea, for people who want to write their code that way.
But, most
Any framework that has convention over configuration has the the problem
that newcomers have to learn the conventions.
I think that one of the biggest stumbling blocks to new users of Rails is
the way associations are described. Just look at the number of questions on
this on SO. M-1 and 1-M