Laravel Pro Tips
🔥 #Laravel Tip: Eloquent’s ‘whereDate’ function is useful, but it prevents the database from using an index, which can effect performance on large tables. Fortunately, it is easy to replace it with ‘whereBetween’:
Matt Kingshott 🏝
⚡️ Database Tip
Creating indexes is a handcraft learned from experience, multiple-column indexes is a lot more complicated. But it doesn't have to be complicated!
Here are 3 simple rules for the column ordering of multiple column indexes, solving 80% of the perf problems.
#Laravel #Eloquent Advice:
If you are making queries by adding a where condition on a string based column, it is better to add an index to the column. Queries are much faster when querying rows with an index column.
#Laravel #Database #PHP
No articles were found.