Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The sending data state in mysql contains a sample analysis using internal temporary tables

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

Editor to share with you the sending data status in mysql includes an example analysis of the use of internal temporary tables. I hope you will gain something after reading this article. Let's discuss it together.

The statement is as follows:

Mysql > desc select id,count (*) from t110 group by id +- -+ | id | select_type | table | partitions | type | possible_keys | key | key_len | ref | rows | filtered | Extra | +- -+-+-- + | 1 | SIMPLE | T110 | NULL | ALL | NULL | 99395 | 100.00 | Using temporary Using filesort | +-+- -- + 1 row in set 1 warning (0.00 sec)

The operation to store the internal temporary table is also under 'sending data', as can be seen in the following debug trace

The operation is to get a piece of data handler::ha_rnd_next in the innodb layer and then query it in the internal temporary table

This line records hp_search, and if it exists, make corresponding changes to heap_update (such as count accumulation, sum bonus, etc.)

Use internal temporary table 1249 Troup3: | | > handler::ha_rnd_next 1250 Troup3: | > rnd_next 1251 Trou3: | > general_fetch 1252 Troup3: | > row_search_mvcc 1253 Troup3: | > row_sel_store_mysql_rec 1254 Troup3 | | > row_sel_store_mysql_field_func 1255 titled 3: | heap_rkey 1268 titled 3: | enter: info: 0x7ffe7caa74d0 inx: 0 1269 titled 3: | > hp_search 1270 titled 3: | | exit: hash: 0x105050504 1271 titled 3: | | exit: found key at 0x7ffe7ceb4880 1272 titled 3: | hp_extract_record 1274 titled 3: | hp_copy_record_data_to_chunks 1280 titled 3: |

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report