Created
May 23, 2020 08:48
-
-
Save deepanshu42/aafde7dbc61f79653f014f7c21232689 to your computer and use it in GitHub Desktop.
Room Database Migration Example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val MIGRATION_1_2 = object : Migration(1, 2) { | |
override fun migrate(database: SupportSQLiteDatabase) { | |
database.execSQL("ALTER TABLE users ADD COLUMN age INTEGER") | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment