Monday, September 19, 2011

How to open a database for cross checking ? (ADB)

First we need to log on to this path : E:\android\android-sdk-windows\platform-tools

This is where our adb.exe is present, once you have cd’d thru to that path you will have to run “adb shell” (to open the remote shell for our emulator device)

Once your command is executed, you will be able to see “#_” similar to our bash in unix. U need to know the folder structure before you “cd” here bcoz tab doesn’t work !!

So our project resides at /data/data/<project name>/databases. Once you have reached this point, the next thing is to “ls” or list all the db files present.

Now, if your db file is present : then we need to open sqlite3 (which comes built in)

#sqlite3 /data/data/<projectname>/databases/contact.db

SQLite version 3.5.9
Enter ".help" for instructions
sqlite> .tables
android_metadata  contact_to_grp



sqlite> select * from contact_to_grp;

image


The rest of the commands are simpler from here.

No comments:

Post a Comment