(1) Open a command prompt, enter: adb, press ENTER, if you get the following a large set of command instructions (1), indicating that the ADB configuration is successful, if prompted "is not an internal or external command, is not a running program or batch file", Then you need to add the directory of Adb.exe files in ANDROIDSDK to the environment variables of the system.
Figure 1
(2) Enter the ADB shell and enter the Linux command environment. (2)
Figure 2
(3) Enter the CD data, enter, enter the root directory of the data folder, 3.
Figure 3
(4) Enter the Ls–l command to view the files under the Data folder, 4.
Figure 4
You can see the Data folder also has a data, we leaf out, again into the Data folder, with Ls–l display the contents of the folder, you can view the Data folder contains a lot of folders (5). Each Android program will generate the corresponding folder here, which is the application-related database.
Figure 5
(5) Use the CD command to access the folder you want to view (the folder name is typically the application's package name), you can see the application's database, you can see that there are two databases in Mar.sqlite3, one is databases, one is LIB. (6)
Figure 6
(6) using the CD Databases command to enter the databases database, and then using the Ls–l command, you can see a database named "test_mars_db" under the database, 7.
Figure 7
(7) So how to operate this database? Using Sqlite3 xxxxx (xxxxx is the database name) into SQLite operating environment (8), where "sqlite>" is similar to the "mysql>" in MySQL, the rest of the operation is almost the same as the SQL operation.
Figure 8
(8) For example, to view the contents of the user table, enter "SELECT * from User;" To get the contents of the user table. (9)
Figure 9
Source: http://blog.sina.com.cn/s/blog_3fe961ae0100qrxn.html
From for notes (Wiz)
How to access SQLite using ADB in Android