Bog'liq Bailey J., Dominguez A., Djermanovic D. - Saving Data on Android (1st Edition) - 2019
Room Persistence Libraries .
Understanding database schemas The first step to creating an app that reads from a SQLite database is to decide on a
database
schema . The schema is the formal declaration of how the data in a
database is
structured . It is good practice to define constants that describe the
database schema in a self-documenting way in their own class or file. These can be
organized into subclasses for databases with multiple tables and should be visible
throughout the scope of the project.
The schema you will define is going to create a database called
todoitems.db , with
one table inside. Inside this table will be three columns:
1. The
primary key column will be an auto incrementing
Integer
named