MySQL script for upgrading to DHIS version 2.3

Hi,

in case you already haven’t noticed: Tran has made a script for upgrading MySQL DHIS databases from version 2.2 to 2.3.

It is important that you back up your production databases before applying this script as there might be minor differences due to what modules you have been running.

The script will remove foreign key references to the source table, make the organisationunit id column auto-increment and then remove the source table.

dhis-upgrade-2.3.sql (11 KB)

One way of executing such a script is from the terminal:

mysql database_name -u user -p < dhis-upgrade-2.3.sql

If you get in trouble please tell us and we will help you fixing the database manually.

I suggest to place -f option because not all the tables mentioned in the script are there.

Caveman

···

2011/6/30 Lars Helge Øverland larshelge@gmail.com

One way of executing such a script is from the terminal:

mysql database_name -u user -p < dhis-upgrade-2.3.sql

If you get in trouble please tell us and we will help you fixing the database manually.


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Just wanted again to emphasize Caveman’s tip that appending “-f” is necessary here which forces the script to continue even if a single command fails. This might well happen since the script also cleans up some outdated tables from earlier releases which might not exist in your database:

mysql database_name -u user -p < dhis-upgrade-2.3.sql -f