How can I query my SQLite database of my application from a terminal?
I need it to debug purposes, and also to che开发者_JAVA百科ck values.
I tried from the Emulator Command Line, I moved to the /data/data//databases folder and executed "sqlite3" from there, but .database command doesn't returns my databases.
There is a special tool in your sdk folder tools
. It is called sqlite3
. Read more here.
THere you'll find all the necessary information like:
From an adb remote shell, you can use the sqlite3 command-line program to manage SQLite databases created by Android applications. The sqlite3 tool includes many useful commands, such as .dump to print out the contents of a table and .schema to print the SQL CREATE statement for an existing table. The tool also gives you the ability to execute SQLite commands on the fly
精彩评论