title: Sum records in one table and check if equal in second
body: <p>Hello I have a bit complicated (for me) issue that I need to solve. I have 2 <code>SQL</code> tables - <code>Payments</code> and <code>Clients</code>. </p>
  
  <p>In table <code>Clients</code> I have few columns but most important are <code>totalPaid</code> and <code>clientID</code>.</p>
  
  <p>In <code>Payments</code> there columns called <code>clientID</code> and <code>amountPaid</code> the issue is that there may be many records for one <code>clintID</code> in <code>Payments</code>.</p>
  
  <p>Now I need to find out whether for every SUM(amountPaid) FROM Payments is the value in Clients (totalPaid) equal. </p>
  
  <p>I'm sorry for posting question without code-providing but may someone be so kind helping me?</p>
  
  <p>Thank you for your time. </p>