Re:LiteFS
by mgkimsal on Wednesday September 21, 2022 @01:17PM
(#32928244)
A for-loop in vanilla anything will do. Nothing special about PHP. Ruby, Python, Java, etc...
[ Parent
| on HN ]
Of course. PHP is the one you will mainly encounter in the wilderness, though.
Most common place I saw N+1 is ActiveRecord (Ruby on Rails).
Because by default, no relationships are loaded and the way AR "loads" stuff makes is extremely easy to create N+M queries on 5 lines of ruby. Then, those people will tell you that you run out of database before you run out of ruby...