Room cannot verify the data integrity. Looks like you've changed schema but
forgot to update the version number. You can simply fix this by increasing the
version number.
Note
: If the app didn't crash, you might have forgotten to press the
START
button earlier, when you ran the app before making the modification. If the
app crashed but you got a different error message, try uninstalling the app
from your device or emulator and repeating the steps above.
Did you expect that crash?
Each time you change the database schema, you need to change the database
version. This will help Room know which migrations to run when building the
database.
The error seems simple enough to fix, right? According to the logcat console, you
just need to increase the version number, so try that now.
Saving Data on Android
Chapter 10: Migrations with Room
raywenderlich.com
176
Open
Do'stlaringiz bilan baham: |