Getting error in migrations ```An error occurred w...
# talk-kratos
e
Getting error in migrations
Copy code
An error occurred while connecting to SQL: error executing migrations/sql/20210817181232000006_unique_credentials.mysql.up.sql, sql: ALTER TABLE `identity_credential_identifiers` MODIFY `identity_credential_type_id` char(36) NOT NULL;: Error 1832: Cannot change column 'identity_credential_type_id': used in a foreign key constraint 'identity_credential_identifiers_type_id_fk_idx'
Working fine in local, error in case of AWS MySQL. Tried with different versions of MySQL but still same. kratos: v0.9.0-alpha.3
Solved I tried these queries and reran migrations. The second query is from file: migrations/sql/20210817181232000006_unique_credentials.mysql.up.sql
Copy code
SET FOREIGN_KEY_CHECKS = 0;
ALTER TABLE `identity_credential_identifiers` MODIFY `identity_credential_type_id` char(36) NOT NULL;