0

how to clear mysql cache inside of stored procedure? I have mysql store procedure called test2.i execute it using another store procedure called test1. test 1 have for each loop and inside of that loop I execute test2. if loop have only one round its get 34.294 sec for execute. if loop have 30 rounds it get 1360.641 sec. that the reason for above question.

  • Does this answer your question? [Clear MySQL query cache without restarting server](https://stackoverflow.com/questions/5231678/clear-mysql-query-cache-without-restarting-server) – P.Salmon Nov 24 '20 at 09:48
  • @P.Salmon i already try that one but not work. I am not 100% sure is it cache problem.but my scenario is it. – Bmt Madushanka Nov 24 '20 at 11:16

1 Answers1

0

If you are asking about the query cache, simply do

SELECT SQL_NO_CACHE ...

to avoid that cache.

If you are asking about the buffer_pool, so state. They are very different.

Rick James
  • 135,179
  • 13
  • 127
  • 222