Level 104
QuestionType::has('questions', '>=', 1)->get()
But >= and 1 are the defaults, so...
QuestionType::has('questions')->get()
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
Hi, I have tables called "QuestionType" and "Questions". and I made a relationship in the "QuestionType" model such as:
Every "QuestionType" hasMany "Questions"
so my question is how to get only those "QuestionTypes" that have more than 1 question.
Please or to participate in this conversation.