1

Am working on an APP that has a) SQLite database, and b) text files and other files that are saved internally during operation. From what I read, app data is stored in a folder data\data\(app name)

Plugging my Motorola Moto X into my development computer, I can access the Internal Storage via the PC as a "drive". The first folder, does NOT have a data folder but there is an android folder. In that folder, there IS a data. Within that folder are folders such as com.ebay.lid, com.gopro.smarty,com.weather.weather and several others, but my app I am working on is not listed.

I have created a SQLite database and saved a text file internally, but have no idea where they went.

Is this a Moto X issue, a Moto X issue accessing via the PC as a drive, or something else?

Thanks

Peter
  • 427
  • 4
  • 14
  • You can only access stuff in data/data on a rooted device. See here for details: http://stackoverflow.com/questions/29285335/how-to-access-data-data-files-of-android-without-a-terminal-on-the-android-devic – Daniel Nugent Oct 30 '15 at 00:16
  • "Plugging my Motorola Moto X into my development computer, I can access the Internal Storage via the PC as a "drive"" -- despite what you're seeing, that is actually what the Android SDK refers to as [external storage](https://commonsware.com/blog/2014/04/08/storage-situation-external-storage.html). "I have created a SQLite database and saved a text file internally, but have no idea where they went" -- they are in [internal storage](https://commonsware.com/blog/2014/04/07/storage-situation-internal-storage.html). You have no direct access to it on production hardware. – CommonsWare Oct 30 '15 at 00:17
  • You need to be rooted to see these folders. – Ahmad Oct 30 '15 at 00:23
  • You have to go to /data/data/con.your package/databases. If you dont have rooted device, and you are un debug mode, you can do in console adb -d shell and then run-as com.yourpackage so then you can access to your app data, such aa databases, shared preferences, cache, etc. – Max Pinto Oct 30 '15 at 00:30
  • I also find this script : https://github.com/Pixplicity/humpty-dumpty-android that allows you to retrieve the database from a real phone then you can read the extracted database with a sqlite sotfware. – Kevin Vincent Jun 28 '16 at 15:07

1 Answers1

1

This method is only available for the emulator. The main reason why you cannot do that is because you don't have access to the database of a real device.

you can see details here : https://stackoverflow.com/a/19195052/5505361

Community
  • 1
  • 1
Kevin Vincent
  • 587
  • 13
  • 28