Optimising MySQL Query

Sraban Pahadasingh    April 14, 2020 05:50 PM

Steps

  1. Expain in select query will produce the number of comparison done, look at the column to assign indexing to column
  2. Remove generalised statements, instead specifiy the required columns
  3. Remove in() and not In() from where clause rather use =. !=
  4. Never use subquery if possible, rather to use join
  5. De-normalize when not necessary to devide tables futher on basis of normalisation.





Comments powered by Disqus