Android Virtual Machine adb shell sqlite3 database, Android sqlite3
Adb shell connection:
// Http://www.cnblogs.com/xiaobo-Linux/
Android stores all data in the data/data directory.
Run the cd command to go to the data/data directory:
Cd/data
LsCommand, you will see StudDB. db, which is our StudDB. db database.
Sqlite3 StudDB. db
This command will open the StudDB. db database. If the StudDB. db database does not exist, a new database named
StudDB. db database. (Note that the database name is case sensitive)
At the sqlite> prompt, enter
The. help Command shows many commands.
. Tables to view all tables. For example, my system has two tables: Student and android_metadata.
Select * from Student;
We found three pieces of data. The display method of this database makes us get used to Oralce, And it looks uncomfortable.
The following two commands change the display mode.
. Mode column
. Header on
Then input select * from Student; we are much more comfortable.
Exit sqlite with the. exit command and return to the # prompt.
Enter exit at the # prompt to exit Linux.