tags:

views:

487

answers:

3

am creating the Android application in that application i created one DB and querying the db values , its working fine. but i need to know where the SQLITE Db is stored in my system can you give me the path please

thank you

+1  A: 

*"All databases, SQLite and others, are stored on the device in /data/data/package_name/databases."* here

You can use android File Explorer to view/pull the file from device.

1) Have you specified any path while you create/open the database.
In my case, I have used SQLiteDatabase.openOrCreateDatabase to create database and it requires the database path as first param.

SQLiteDatabase sqldb = SQLiteDatabase.openOrCreateDatabase(DATABASE_PATH+DATABASE_NAME, null);

2) If you are using something like this
openOrCreateDatabase("test.db", this.MODE_APPEND, null);

Your database will be at /data/data/package_name/databases

bhatt4982
+5  A: 

By default, the sqlite database will be in the following directory:

/data/data/YOUR_APP_NAMESPACE/databases/YOUR_DB_NAME.db

So for example, the actual database that holds SMS messages in your phone is:

/data/data/com.android.providers.telephony/databases/mmssms.db

In the emulator you can access these files directly; when connecting to a real phone however you will need root access to access the db files directly.

The android doc gives you a quick overview: http://developer.android.com/intl/de/guide/developing/tools/adb.html

Tao
A: 

Hi, for accessing your database.if your are not able to find data/data/etc..

then go to eclipse select Window>open Perespective> other >DDMS and then find data/data/package/databases/your db

Amandeep Singh