title: SQL dividing column by a number in another table
body: <p>I have two tables:</p>
  
  <pre><code>total_table = 
  | Title | Value |
  |-------|-------|
  | total |   20  |
  
  breakdown_table =
  |  Title | Value |
  |--------|-------|
  |  total |   20  | (this is the same as the above table)
  | type a |   10  |
  | type b |    5  |
  | type c |    5  |
  </code></pre>
  
  <p>I would like to create a new table which includes both columns from <code>breakdown_table</code> but adds a 3rd column that shows the breakdown percentages (100%, 50%, 25%, 25%). How can I do this without hardcoding the denominator?</p>
  
  <p>Here's some syntax I've tried but it keeps giving me errors about commas and equijoin. I'm not trying to join the tables with a key, I just want to use the single value in the <code>total_table</code>.</p>
  
  <pre><code>data_out = SELECT breakdown_table.*,
                    breakdown_table.Value / total.Value
             FROM breakdown_table, total_table;
  </code></pre>