I want to have an SQLite db in my flutter app, so i followed this flutter cookbook: https://flutter.dev/docs/cookbook/persistence/sqlite
I open the database with the following path: join(await getDatabasesPath(), 'doggie_database.db')
exactly like the tutorial. I ran the app on my Android phone (not emulator).
Now i want to inspect the database file on my PC, but i cannot find the file on my phone.
I debugged the above statement and it resolves to /data/user/0/*mypackage*.*app-name*/databases/doggie_database.db
, but i can't find the folder /data
(only Android/data
) or the file in my file manager neither on my phone nor on my pc.
Where is the file and how can i extract it from my phone?
I found the solution that works on Android. It is possible to extract the database file by using adb.
run-as *mypackage*.*app-name*
/data/data/*mypackage*.*app-name*
foldercp doggie_database.db /storage/self/primary/Documents
)Use these 2 articles as reference:
https://denniskubes.com/2012/09/25/read-android-data-folder-without-rooting/
https://blog.shvetsov.com/2013/02/access-android-app-data-without-root.html