-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/6894/
-----------------------------------------------------------
Review request for hive.
Description
-------
By upgrading a MySQL metastore sometimes the schema get's into a foreign key
issue:
+----------------------------------------+
| Inserted table columns into COLUMNS_V2 |
+----------------------------------------+
| Inserted table columns into COLUMNS_V2 |
+----------------------------------------+
+--------------------------+
| Completed migrating idxs |
+--------------------------+
| Completed migrating idxs |
+--------------------------+
ERROR 1025 (HY000) at line 250 in file: '008-HIVE-2246.mysql.sql': Error on
rename of './metastore/COLUMNS_OLD' to './metastore/#sql2-14e6-6eb' (errno: 152)
These patch disables FK checks before the table will be copied, and enable them
after.
This addresses bug HIVE-3424.
https://issues.apache.org/jira/browse/HIVE-3424
Diffs
-----
metastore/scripts/upgrade/mysql/008-HIVE-2246.mysql.sql 3ac8d2e
Diff: https://reviews.apache.org/r/6894/diff/
Testing
-------
Thanks,
Alexander Alten-Lorenz