Copy sqlite database from device to PC

xain picture xain · May 16, 2011 · Viewed 11.4k times · Source

I have an android program that stores its information in a sqlite database. Will it be straighforward to copy that db file to a pc once the device is plugged via USB or should a special functionality be written in the program itself to dump the db contents to a file under the /sdcard directory ?

Thanks

Answer

superfell picture superfell · May 16, 2011

You can use the adb pull command to read a file from the teathered device to your desktop, e.g. adb pull /data/data/com.foo.bar/databases/MyDatabase