Database

For When Things Get Gnarly in Eloquent

Jonathan Reinink has written some excellent content around Eloquent and this article is one that I reference frequently. Jonathan walks us through handling sticky situations when we need to get a single record back from a relationship without causing N+1 issues.

Dynamic Relationships in Laravel using Subqueries →

May 20, 2020