Exploring Databases on the Emulator and Available Devices

Because many content providers in Android use SQLite databases (http://www.sqlite.org/), you can use tools provided both by Android and by SQLite to examine the databases. Many of these tools reside in the \android-sdk-install-directory\tools subdirectory.

One of the tools is a remote shell on the device that allows you to execute a command-line SQLite tool against a specified database. You'll see in this section how to use this command-line utility to examine the built-in Android databases.

Android uses another command-line tool called Android Debug Bridge (adb), which is available as tools\adb.exe adb is a special tool in the Android toolkit that most other tools go through to get to the device. However, you must have an emulator running or an Android device connected for adb to work. You can find out whether you have running devices or emulators by typing this at the command line:

adb devices

If the emulator is not running, you can start the emulator by typing this at the command line:

\tools\emulator.exe

0 0

Post a comment