You need to know about the query execution plan

Is there a way to view the mysql / oracle query execution plan as java debugging. I want to know how mysql / oracle fulfills our query and what are the steps related to the execution.

+4
source share
2 answers

For mysql you should use

EXPLAIN <query> 

eg.

 EXPLAIN SELECT * FROM tableX 

see mysql link

For the oracle there is something similar, but more detailed:

 EXPLAIN PLAN FOR <query> 

eg.

 EXPLAIN PLAN FOR SELECT * FROM tableX 

see also: link for oracle

+3
source

Source: https://habr.com/ru/post/1391386/


All Articles