# Run pt-online-schema-change on a deprecated ROW\_FORMAT table

**URL:** https://forums.percona.com/t/run-pt-online-schema-change-on-a-deprecated-row-format-table/8412
**Category:** Percona Toolkit
**Tags:** mysql, percona
**Created:** [December 17, 2020, 10:23am UTC](https://forums.percona.com/t/run-pt-online-schema-change-on-a-deprecated-row-format-table/8412 "2020-12-17T10:23:14Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![duronrulez](https://avatars.discourse-cdn.com/v4/letter/d/7c8e57/32.png) [@duronrulez](https://forums.percona.com/u/duronrulez)
#### Post date: [December 17, 2020, 10:23am UTC](https://forums.percona.com/t/run-pt-online-schema-change-on-a-deprecated-row-format-table/8412/1 "2020-12-17T10:23:14Z")

</div>

Hey,

trying to run pto on a table that has ROW\_FORMAT=fixed.

Mysql 5.6 used to silently convert to compact, but mysql 5.7 just straight up refuses to create a table in that format.

Unfortunately this means pto is unusable in tables like this. I am trying to remove all table definition row\_formats where we have them (so it defaults to whatever is default for the version), but for that i need an alter, which i cannot run because pto cannot create the new table. I cannot run straight alter table commands as some tables are quite big and it will cause delays and cluster lock ups.

Any ideas how i can solve the issue? Hopefully other than going in and editing the pto script.

My only thought so far is that i can run pto through our proxysql and using the proxysql query rewriting features to force removal of the row\_format clause on table creation when running pto. But that sounds too hacky.

---

<div class="post-metadata">

### Author: ![duronrulez](https://avatars.discourse-cdn.com/v4/letter/d/7c8e57/32.png) [@duronrulez](https://forums.percona.com/u/duronrulez)
#### Post date: [December 17, 2020, 10:53am UTC](https://forums.percona.com/t/run-pt-online-schema-change-on-a-deprecated-row-format-table/8412/2 "2020-12-17T10:53:26Z")

</div>

just found out i can use: --[no]create-tmp-table

[pt-online-schema-change](https://www.percona.com/doc/percona-toolkit/2.0/pt-online-schema-change.html#cmdoption-pt-online-schema-change--)

Sorry for wasting time, you can consider this question closed.

EDIT: OK, i spoke too soon 🙂 i cannot find that option in pto 3.0 [https://www.percona.com/doc/percona-toolkit/3.0/pt-online-schema-change.html](https://www.percona.com/doc/percona-toolkit/3.0/pt-online-schema-change.html)any ideas why thats missing? Looks like it got removed in version 2.1

EDIT2: And if i have to edit the pto script something like this makes sense to me, from 10695 line:

```auto
my $quoted = $q->quote($orig_tbl->{db}, $new_table_name);
      my $sql = $ddl;
      $sql =~ s/ROW_FORMAT=.*?( |$)/ /m; # this is my change - replace any ROW_FORMAT statements with empty ones, making sure it uses the engine default
      $sql =~ s/\ACREATE TABLE .*?\($/CREATE TABLE $quoted (/m;
but again, this feels veeery hacky.

EDIT3: Turning off innodb_strict_mode for the duration of the change also seems to be an option:
 --set-vars innodb_strict_mode="off"

```
