페이지 이력
Flyway is an automatic DB Migration solution. It is automatically run on install package during update.
But if there is error , then we should check the log file which shows the problem (specific query which makes the error are also shown) as well as flyway db table to see the migrating status,
then run the migrate using bat file or do the total manual db update.
Screenshot below shows sql files in V7100 install package.
...
If the flyway was NEVER been used before, then we need to let Flyway knows which version will be baseline to start excuting executing the query.
Meaning, define the current version and start "migrate" command on flyway.
Then Flyway will automatically excute execute the sql file one by one in order to grow number from the the baseline.
...
(sql_postgres : sql location for postgresql. If db type is MSSQL then : sql_mssql )
"C:\MagicInfo Premium\flyway\flyway.cmd" -configFiles="C:\MagicInfo Premium\conf\config.properties","C:\MagicInfo Premium\flyway\conf\placeholder.conf" -locations=filesystem:"C:\MagicInfo Premium\flyway\sql_postgres" info |
---|
During the db update if db update fails, then the "State" changes to "Pending" on the fault sql file.
You can find the log & status on log file and db table.
C:\MagicInfo Premium\flywaylog.txt table : flyway_schema_history |
---|
You can try re-update using this command.
"C:\MagicInfo Premium\flyway\flyway.cmd" -configFiles="C:\MagicInfo Premium\conf\config.properties","C:\MagicInfo Premium\flyway\conf\placeholder.conf" -locations=filesystem:"C:\MagicInfo Premium\flyway\sql_postgres" migrate |
---|
The command is long, but from V8 we support bat file which makes these easier. ( C:\MagicInfo Premium\flyway\mis.bat )
Go to this directory C:\MagicInfo Premium\flyway\mis.bat Run the bat file using command. mis.bat info mis.bat migrate |
---|
When there is an issue during updating....
...