title: OneToMany relation with nested ManyToOne relation returns broken relation entity
body: <p>I'm creating a structure where I have Repositories, Contributions and Users.</p>
  
  <p>A repository has multiple contributions done by different users. It is important that I know the count property on the contribution.</p>
  
  <p>But when I create a new Repository entity without connections I get weird behaviour.</p>
  
  <p><a href="https://github.com/Alfalfamale/TypeOrmIssue" rel="nofollow noreferrer">Example Code</a></p>
  
  <p>My <code>index.ts</code>:</p>
  
  <pre class="lang-ts prettyprint-override"><code>import "reflect-metadata";
  import {createConnection, getRepository} from "typeorm";
  import {Repository} from "./entity/Repository";
  
  createConnection().then(async connection =&gt; {
  
      const newRepo = new Repository();
      newRepo.name = 'test';
      newRepo.description = 'no contributions made';
      await connection.manager.save(newRepo);
  
      const RepoRepository = getRepository(Repository);
      const repos = await RepoRepository.find();
  
      console.log(repos);
      console.log(repos[0].contributions);
  
      await connection.manager.save(repos);
  
      connection.close();
  
  }).catch(error =&gt; console.log(error));
  </code></pre>
  
  <p>my console output:</p>
  
  <pre class="lang-console prettyprint-override"><code>repos [ Repository {
      name: 'test',
      description: 'no contributions made',
      contributions: [ [Contribution] ] } ]
  contributions [ Contribution { count: null, user: null } ]
  </code></pre>
  
  <p>which is weird because I never created any contributions.</p>
  
  <p>And the <code>connection.manager.save(repos);</code> call errors out on:</p>
  
  <pre class="lang-shell prettyprint-override"><code>{ QueryFailedError: ER_BAD_NULL_ERROR: Column 'count' cannot be null
      at new QueryFailedError (D:\GitHub\Issue\src\error\QueryFailedError.ts:9:9)
      at Query.&lt;anonymous&gt; (D:\GitHub\Issue\src\driver\mysql\MysqlQueryRunner.ts:164:37)
      at Query.&lt;anonymous&gt; (D:\GitHub\Issue\node_modules\mysql\lib\Connection.js:502:10)
      at Query._callback (D:\GitHub\Issue\node_modules\mysql\lib\Connection.js:468:16)
      at Query.Sequence.end (D:\GitHub\Issue\node_modules\mysql\lib\protocol\sequences\Sequence.js:83:24)
      at Query.ErrorPacket (D:\GitHub\Issue\node_modules\mysql\lib\protocol\sequences\Query.js:90:8)
      at Protocol._parsePacket (D:\GitHub\Issue\node_modules\mysql\lib\protocol\Protocol.js:278:23)
      at Parser.write (D:\GitHub\Issue\node_modules\mysql\lib\protocol\Parser.js:76:12)
      at Protocol.write (D:\GitHub\Issue\node_modules\mysql\lib\protocol\Protocol.js:38:16)
      at Socket.&lt;anonymous&gt; (D:\GitHub\Issue\node_modules\mysql\lib\Connection.js:91:28)
    message: 'ER_BAD_NULL_ERROR: Column \'count\' cannot be null',
    code: 'ER_BAD_NULL_ERROR',
    errno: 1048,
    sqlMessage: 'Column \'count\' cannot be null',
    sqlState: '23000',
    index: 0,
    sql:
     'INSERT INTO `contribution`(`count`, `repositoryName`, `employeeGithub`) VALUES (NULL, \'test\', NULL)',
    name: 'QueryFailedError',
    query:
     'INSERT INTO `contribution`(`count`, `repositoryName`, `employeeGithub`) VALUES (?, ?, ?)',
    parameters: [ null, 'test', null ] }
  </code></pre>
  
  <p>My Entities:</p>
  
  <pre class="lang-ts prettyprint-override"><code>@Entity()
  export class Repository {
  
      @PrimaryColumn()
      name: string;
  
      @Column("text")
      description: string;
  
      @OneToMany(type =&gt; Contribution, contribution =&gt; contribution.repository, {eager: true, cascade: true})
      contributions: Contribution[];
  }
  
  @Entity()
  export class Contribution{
  
      @ManyToOne(type =&gt; Repository, repository =&gt; repository.contributions, {primary: true})
      repository: Repository;
  
      @ManyToOne(type =&gt; User, user =&gt; user.contributions, {eager: true, cascade: true, primary: true})
      @JoinTable()
      user: User;
  
      @Column()
      count: number;
  }
  
  @Entity()
  export class User{
  
      @PrimaryColumn()
      github: string;
  
      @OneToMany(type =&gt; Contribution, contribution =&gt; contribution.user)
      contributions: Contribution[];
  }
  </code></pre>
  
  <p>What I tried:</p>
  
  <p>Removing the <code>eager</code> on the ManyToOne from Contribution to User fixes the error and I correctly get an empty contributions array. But it isn't really a solution for the repositories that do have contributions. </p>
  
  <p>The main question is: Am I doing it wrong or is this not something that works in typeorm?</p>