title: Translating a query to use Zend_Db_Select
body: <p>I'm having some problems translating this query to use ZF's <code>Zend_Db_Select</code>:</p>
  <pre><code>SELECT b.id, b.title, b.description 
  FROM memberships AS m
  JOIN blogs AS b ON b.id = m.blog_id 
  WHERE m.user_id = ? 
  ORDER BY m.created
  LIMIT 0, 30
  </code></pre>
  <p>(this query works and returns results)</p>
  <p><code>Memberships</code> is a link table between <code>blogs</code> and <code>users</code>. It's a simple <code>| id | blog_id | user_id |</code> affair.</p>
  <p>Here's what I have so far:</p>
  <pre><code>// $table = Zend_Db_Table instance, $id = a user id
  $select = $table-&gt;select()
  -&gt;from(array('m' =&gt; 'memberships'), array('b.id', 'b.title', 'b.description'))
  -&gt;join(array('b' =&gt; 'blogs'), 'b.id = m.blog_id')
  -&gt;where('m.user_id = ?', (int) $id)
  -&gt;order('m.created DESC')
  -&gt;limit(0, 30);
  </code></pre>
  <p>This is the (strange (to me)) error I'm getting:</p>
  <blockquote>
  <p><code>#0: Select query cannot join with another table</code></p>
  <p>Occurred on line 211 of <code>D:\...\library\Zend\Db\Table\Select.php</code>.</p>
  </blockquote>
  <p>Thanks for your help.</p>