Reducing execution time of MySQL UPDATE -


i want optimize execution time (50 sec) of following update command.

    update matches     join players b      on a.player1_name = b.player_name     set a.player1_id = b.id     a.player1_id = 0 

the table matches has approximately 10000 entries , table players 4000 entries.

make sure have indexes on a.player1_name, b.player_name , a.player1_id.


Comments

Popular posts from this blog

PHP DOM loadHTML() method unusual warning -

python - How to create jsonb index using GIN on SQLAlchemy? -

c# - TransactionScope not rolling back although no complete() is called -