MySQL Forums
Forum List  »  Partitioning

Locking
Posted by: Alex Brown
Date: October 14, 2020 01:32AM

Hi,

I am trying to find more information on what locks would be applies when using the command:

ALTER TABLE ... DROP PARTITION ...

I am particularly interested in how this compares to TRUNCATE PARTITION

Whilst I can find documentation on truncate I cant seem to find anything conclusive on drop.

I have a hunch that DROP will lock the whole table whereas truncate will prune lock, only locking the data to be deleted.

Hoping someone here can provide some clarification, and or point me to the correct docs.

Here are some of the places I have already looked:
https://dev.mysql.com/doc/refman/5.7/en/partitioning-limitations-locking.html
https://dev.mysql.com/doc/refman/5.6/en/lock-tables.html
https://dev.mysql.com/doc/refman/5.6/en/innodb-locking.html

Would like to know what happens in V5.6 / 5.7

Options: ReplyQuote


Subject
Views
Written By
Posted
Locking
593
October 14, 2020 01:32AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.