title: Association "is invalid" when model is saved
body: <p>I have a Club model and a Member model, which are associated through a Membership model. In other words</p>
  
  <pre><code>class Club &lt; ActiveRecord::Base
    has_many :members, :through =&gt; :memberships
  end
  
  class Member &lt; ActiveRecord::Base
    has_many :clubs, :through =&gt; :memberships
  end
  </code></pre>
  
  <p>However, when I attempt to create a new member and add it to a club, I get an error saying that the club is invalid.</p>
  
  <pre><code>&gt; club = Club.find(1)
  &gt; member = Member.new(:name =&gt; 'Member Name')
  &gt; member.clubs &lt;&lt; club
  &gt; member.save
  </code></pre>
  
  <p>The <code>member.save</code> statement will return false. Looking at the member.errors.messages, I find</p>
  
  <pre><code>&gt; member.errors.messages
  @messages={:clubs=&gt;["is invalid"]}
  </code></pre>
  
  <p>The really bizarre thing is that this does not happen for my Development environment (using sqlite3), but only on my EngineYard deployment using mySQL.</p>