I want to decrease the size of disk space occupied by some tables. For that, I want to run optimize (any better ideas?).
How would I optimize with the pt-online-schema-change command? The option would be --alter = “ENGINE = InnoDB”, same as shown below?
pt-online-schema-change --alter = “ENGINE=InnoDB” --analyze-before-swap --user= --password= --execute D=, t=;
I’m running the command like this, and the error is returning me:The new table <database>
._ <table> _new
does not have a PRIMARY KEY or a unique index which is required for the DELETE trigger.Please check you have at least one UNIQUE and NOT NULLABLE index.