I am using MySQL Server version: 5.6.15 Homebrew
. I need to add new null
column. alter table
requires no metadata
lock. In order to avoid this MySQL 5.6
introduced algorithm=inplace
. Here is the reference articles http://www.mysqlperformanceblog.com/2013/07/05/schema-changes-whats-new-in-mysql-5-6/.
Executing the following sql throws
mysql> alter table candidate_candidate add column responsible_user_id int, algorithm=INPLACE, lock=NONE;
ERROR 1845 (0A000): ALGORITHM=INPLACE is not supported for this operation.
Try ALGORITHM=COPY.
Is there a way to add column
without affecting app read/write
?
alter table
requires NO metadata lock? I guess it requires such a lock. – asgs Jul 16 '18 at 9:33