You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(Step5. If I change the index name in advance, it worked normally)
login mysql
use test01 database
rename index_tools_01 with index_tools_03
rename index_tools_02 with index_tools_04
do mysqldef (step4)
$ ./mysqldef -uroot --file=schema.sql --dry-run test01
-- dry run --
ALTER TABLE tools ADD key index_tools_01(created_at, updated_at);
ALTER TABLE tools ADD key index_tools_02(name);
ALTER TABLE tools DROP INDEX index_tools_03;
ALTER TABLE tools DROP INDEX index_tools_04;
It would be considered as a limitation that sqldef does not generate RENAME INDEX here.
However, generating -- Nothing is modified -- is a bug. I fixed sqldef to detect the change properly in 7e4a2dd and it now generates DROP INDEX + ADD key, while I'm not sure if that's what you really wanted. Please try v0.5.12 which is being released at https://travis-ci.org/k0kubun/sqldef/builds/643693973.
Step to reproduce
My environment:
Step1. Create database
Step2. Initialize table
Step3. Write schema.sql file.
index_tools_01
columnsindex_tools_02
columnsStep4. Do mysqldef, but it does not recoginze modified two index
(Step5. If I change the index name in advance, it worked normally)
test01
databaseindex_tools_01
withindex_tools_03
index_tools_02
withindex_tools_04
Are these also sqldef limitations ?
The text was updated successfully, but these errors were encountered: