Is "LOCK=EXCLUSIVE" supported in "ALTER TABLE ... CONVERT TO" statement?

Dear community,

I get the following error:

MariaDB> ALTER TABLE events CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci LOCK=EXCLUSIVE;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'LOCK=EXCLUSIVE' at line 1

I haven't found anything in the documentation that this combination is not supported so it should work.

Any hint what have I overlooked?

MariaDB v10.5.15.

Answer Answered by Daniel Black in this comment.

The options to lock are comma separated. So:

 ALTER TABLE events
CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci ,
LOCK=EXCLUSIVE;

Comments

Comments loading...
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.