title: Yii2: can't create sql command using innerJoin
body: <p>I am not that good at <code>SQL</code> but i do as much as i can for the little knowledge i have..</p>
  
  <p>I have made a single a flat <code>SQL</code> string with the help from a friend that gathers data from a table using a relative table from an initial data from the first table, the <code>SQL</code> was made like this:</p>
  
  <pre><code>SELECT id, username, auth_assignment.created_at
  FROM `user` JOIN `auth_assignment`
  ON (user.id = auth_assignment.user_id)
  JOIN `auth_item`
  ON (auth_item.name = auth_assignment.item_name)
  WHERE auth_item.name = 'Admin'
  </code></pre>
  
  <p>the initial data to look is <code>Admin</code> so everything works in that side, but i tried to simulate this <code>SQL</code> using <code>Yii2</code> functions.. so far i have made this code</p>
  
  <pre><code>$query = new Query;
  
  $command = $query-&gt;select('id, username')
      -&gt;innerJoin('auth_assignment', ['user.id'=&gt;'auth_assignment.user_id'])
      -&gt;innerJoin('auth_item', ['auth_item.name'=&gt;'auth_assignment.item_name'])
      -&gt;where('auth_item.name = :name', [':name'=&gt;$name])-&gt;createCommand();
  
  var_dump($command-&gt;query());
  </code></pre>
  
  <p>this returns an <code>SQLSTATE</code> error:</p>
  
  <pre><code>SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'INNER JOIN `auth_assignment` ON `user`.`id`='auth_assignment.user_id' INNER JOIN' at line 1
  The SQL being executed was: SELECT `id`, `username` INNER JOIN `auth_assignment` ON `user`.`id`='auth_assignment.user_id' INNER JOIN `auth_item` ON `auth_item`.`name`='auth_assignment.item_name' WHERE auth_item.name = 'Admin'
  </code></pre>
  
  <p>i checked the method <code>$command-&gt;sql;</code> to know how the <code>SQL</code> was being generated.. but i really don't know how to fix it due to my lack of my knowledge to <code>SQL</code> and lack of understanding to <code>yii2</code> api documentation</p>
  
  <p><code>SQL</code> is generated like this:</p>
  
  <pre><code>SELECT `id`, `username` INNER JOIN `auth_assignment` ON `user`.`id`=:qp1 INNER JOIN `auth_item` ON `auth_item`.`name`=:qp2 WHERE auth_item.name = :name 
  </code></pre>
  
  <p>i appreciate any help</p>