How to get this query using the Laravel query builder?
Hi everyone,
I'm new to joins and I created this query:
select
threads.*, count(replies.id) replies_count
from threads
where replies_count = 0
left join replies
on replies.thread_id = threads.id
group by threads.id
How do I get this query into a Laravel Query Builder object?