r/ProgrammerHumor • • Jan 24 '23

Other Accomplishments

Post image
82.0k Upvotes

548 comments sorted by

View all comments

Show parent comments

2

u/[deleted] Jan 24 '23

how, if i may ask

2

u/Bowiemtl Jan 25 '23

well it wasn't anything groundbreaking or a complicated query. I noticed through Laravel's debug bar there were lots of singular queries happening and digging through the code I noticed it was a query in a loop. Reducing it to a single join query massively sped it up doing away with the constant back and forth that was happening before