Undestand the basics to avoid n+1 queries
Start your road to avoid n+1 queries like a pro, with my free ebook “N+1 queries basics”…
- Understand preload, eager_load, includes and joins and the difference between them.
- Learn to identify when active record will execute your query.
- Learn the tools that can help you detect n+1 queries before they hit production.