Return Clients With Two Charges

I have two tables, one of clients and other charges, I wanted to know how to return only clients with two charges in arrears? Winning something like ‘ < \’’ . date(‘Y-m-d’) . ‘\’’

You can add something like this to your query:

WHERE (SELECT count(*) FROM charges WHERE charges.client_id = AND < " . $arrears _date . ") = 2)

Thanks for your the first case I could do, but our system has two forms of payment in the two different tables, and I want to check in or other charges has expired, if one of them has returned the client, but is not working this way. I believe the problem is with "with", if you have no corresponding "cobrancas" the condition does not return even if you have "boletos" corresponding to condition. Could you help me? I thank you.