title: Recursive query which aggregates child items in sqlite3
body: <p>I have a table of parent-child relationships:</p>
  <pre><code>CREATE TABLE item_parent(item_hash, parent_hash);
  CREATE UNIQUE INDEX item_parent_unique ON item_parent(item_hash, parent_hash);
  CREATE VIEW item_timestamp AS SELECT item_hash, item_timestamp FROM [...]
  </code></pre>
  <p>I would like to create a view which aggregates these into the following columns:</p>
  <pre><code>item_hash (from the table)
  child_count (recursively summarized)
  newest_timestamp (joined from item_timestamp, most recent timestamp of all the items which are in the tree)
  </code></pre>
  <p>I understand I'm supposed to do something with <code>WITH RECURSIVE</code>, but having trouble figuring out the syntax. I've looked around SO already.</p>