title: Join queries for jsonb fields
body: <p>Can anyone help me with a join query for tables with jsonb fields?</p>
  
  <p>If I have two tables and each has a jsonb column <code>value</code> and I need to run some join queries.</p>
  
  <p>Let's say <code>value</code> field in each table has rows similar to this</p>
  
  <p><code>accounts</code></p>
  
  <pre><code>[{
        "account-id":"c3ff14f9-b9ce-4daf-930b-3500e0efbdc9",
        "name": "foo"
    }...]
  </code></pre>
  
  <p><code>account-balances</code></p>
  
  <pre><code>[{
      "account-id": "c3ff14f9-b9ce-4daf-930b-3500e0efbdc9",
      "amount": 31415926
  }...]
  </code></pre>
  
  <p>You can see that data in tables is associated via "account-id" property.
  Now I need to find all accounts that have corresponding balance > 0.</p>