title: sphinx and one-to-many associations
body: <p>The examples I've seen for sphinx search don't really use joins. If I had a schema like this (one book has multiple reviews),</p>
  
  <pre><code>create table book ( id int auto_increment, title varchar(200), summary longtext );
  create table reviews ( id int auto_increment, book_id int, review longtext );
  </code></pre>
  
  <p>What sort of query should I give to sphinx so that I can search for the words in the review and it will return the corresponding book. If I use a regular inner join each review will be a single document and that doesn't correspond to what's visible on the site (single page contains book info and all reviews).</p>
  
  <p>What do you suggest? Should I create a denormalized table for the search documents and use the rendered page as input e.g.:</p>
  
  <pre><code>create table sphinx_input ( 
     id int, -- corresponds 1..1 to book.id
     contents longtext -- everything on the page
  );
  </code></pre>
  
  <p>and modify this for every change to books and reviews?</p>