Level 88
You can use a raw query for that! So in your case something like this
Payment::whereRaw('select MAX(amount) from payments where amount > 50')->get();
Documentation: https://laravel.com/docs/5.8/queries#raw-expressions
For some more context: https://laravel.com/docs/5.8/queries#where-exists-clauses Note that this works for all methods like whereIn and so on. You can just pass in a callback and perform some query there