공부용 블로그

explain을 썼을 때 처리량의 변화 (진짜 영향을 미치는것일까?) 본문

설계/RDBMS

explain을 썼을 때 처리량의 변화 (진짜 영향을 미치는것일까?)

tomato212 2018. 12. 17. 22:18


Q. index를 탔는지 확인하기 위해 select문에 explain을 썼는데 throughput이 10배 이상 증가했다.

explain은 쿼리문의 실행계획 정보를 보여주는 것인데 처리량과는 어떤 관계가 있는거지?


아래 MySQL 페이지를 참고  (https://dev.mysql.com/doc/refman/8.0/en/explain-output.html)


EXPLAIN returns a row of information for each table used in the SELECT statement. It lists the tables in the output in the order that MySQL would read them while processing the statement. MySQL resolves all joins using a nested-loop join method. This means that MySQL reads a row from the first table, and then finds a matching row in the second table, the third table, and so on. When all tables are processed, MySQL outputs the selected columns and backtracks through the table list until a table is found for which there are more matching rows. The next row is read from this table and the process continues with the next table.



A. 영향을 미치지 않는다. 


explain은 실행계획 정보를 보여주는 것이 맞고, jmeter에서는 쿼리에 대한 결과값으로 해당 데이터가 아니라 실행계획정보를 처


리한 것이다. jmeter에서는 어쨌든 작업을 처리했으므로 throughput을 증가시키고 데이터를 가져오는 것보다 실행계획 정보를 


보여주는 것이 훨씬 더 빠른 처리를 할 수 있기 때문에 쓰루풋이 엄청나게 증가했던 것이다.

'설계 > RDBMS' 카테고리의 다른 글

Cubrid Architecture  (0) 2018.12.19
Time Series Database와 RDBMS의 차이점  (0) 2018.12.18
MariaDB 설치  (0) 2018.12.16
MonetDB 설치  (0) 2018.12.15
MonetDB Architecture  (0) 2018.12.13