Skip to content

Instantly share code, notes, and snippets.

@BramYeh
Created November 28, 2017 12:13
Show Gist options
  • Save BramYeh/2fd7ffdc1c60eb156262087e025ecfb0 to your computer and use it in GitHub Desktop.
Save BramYeh/2fd7ffdc1c60eb156262087e025ecfb0 to your computer and use it in GitHub Desktop.
Schema verison 1 for Migrate SQLiteOpenHelper and SQLiteDatabase to Room (with Testing)
{
"formatVersion": 1,
"database": {
"version": 1,
"identityHash": "99c7946712f93a4d723efbe10a500eb0",
"entities": [
{
"tableName": "users",
"createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`userid` INTEGER NOT NULL, `username` TEXT, PRIMARY KEY(`userid`))",
"fields": [
{
"fieldPath": "userid",
"columnName": "userid",
"affinity": "INTEGER",
"notNull": true
},
{
"fieldPath": "username",
"columnName": "username",
"affinity": "TEXT",
"notNull": false
}
],
"primaryKey": {
"columnNames": [
"userid"
],
"autoGenerate": false
},
"indices": [],
"foreignKeys": []
}
],
"setupQueries": [
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment