Commit 4c65582e authored by Fabius's avatar Fabius Committed by Toni Beier

Datenbank Upgrade um Absturzt bei Update zu vermeiden #25

parent be160a33
......@@ -17,7 +17,7 @@ public class ASiSTConstants {
public static final int NOTIFICATION_ID_UPDATE = 6951;
public static final String DB_NAME = "ASiST.db";
public static final int DB_VERSION = 8; // DB_Version 4 ab myTU Version
public static final int DB_VERSION = 9; // DB_Version 4 ab myTU Version
public static final String FEEDBACK_LECTURER_MODE = "feedback.lecturer.mode";
......
......@@ -83,6 +83,10 @@ public class DatabaseHelper extends OrmLiteSqliteOpenHelper {
// nothing to do
}
}
else if(oldVersion != newVersion && newVersion == 9)
{
database.execSQL("ALTER TABLE 'course' ADD COLUMN type INTEGER NOT NULL DEFAULT (0);");
}
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment