MySQL Forums
Forum List  »  Newbie

Re: real time performance issues
Posted by: Peter Brawley
Date: March 28, 2020 11:18AM

The stored procedure uses a cursor? Most cursors can be replaced by equivalent sql which runs an order of magnitude faster.

It's much easier to optimise a query once it\s extracted from an sproc. Read about Explain ...

https://dev.mysql.com/doc/refman/5.7/en/explain.html

https://dev.mysql.com/doc/refman/5.7/en/explain-output.html

https://www.eversql.com/mysql-explain-example-explaining-mysql-explain-using-stackoverflow-data/

then run Explain format=json (or in 8.0, explain analyze), optimise query index use and other problems in it.



Edited 1 time(s). Last edit at 03/28/2020 11:19AM by Peter Brawley.

Options: ReplyQuote


Subject
Written By
Posted
March 28, 2020 02:26AM
Re: real time performance issues
March 28, 2020 11:18AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.