MySql - slow sending data phase

前端 未结 6 1168
醉话见心
醉话见心 2020-12-14 01:03

One of my queries on MySQL 5.0.45 is running slow in \"sending data\" phase. The query is a simple select, returns about 300 integer ID fields as result set.

mysq         


        
6条回答
  •  猫巷女王i
    2020-12-14 01:37

    Your query spends 2.127019 to execute the query. This is probably because you have a large amount of data, and your are missing an index on the destination_id column. Try :

    CREATE INDEX index_destination_id ON directions (destination_id);

    Then your request will run smoothly.

提交回复
热议问题