Flutter apps can make use of the SQLite databases via the
sqflite plugin available on pub.dev.
This recipe demonstrates the basics of using sqflite
to insert, read, update, and remove data about various Dogs.

If you are new to SQLite and SQL statements, review the
SQLite Tutorial to learn the basics before
completing this recipe.

This recipe uses the following steps:

Add the dependencies.

Define the Dog data model.

Open the database.

Create the dogs table.

Insert a Dog into the database.

Retrieve the list of dogs.

Update a Dog in the database.

Delete a Dog from the database.

1. Add the dependencies

To work with SQLite databases, import the sqflite and path packages.

The sqflite package provides classes and functions to
interact with a SQLite database.