Talk to Felipe,
This was a question I always had, I posted in thousands of places and forums and nothing!
What I got was a method that exports the .bd file from SQLite, and with that file I can see it in a program like DB Browser for SQLite for example.
It's a good Lusitano way, but at least for me it works, do the following:
Place this method in your MainActivity, or whatever your application's main class is:
private void banco() {
File f = new File("/data/data/br.com.packagedoseuprojeto/databases/ame.db");
FileInputStream fis=null;
FileOutputStream fos=null;
try
{
fis=new FileInputStream(f);
fos=new FileOutputStream("/mnt/sdcard/db_dump.db");
while(true)
{
int i=fis.read();
if(i!=-1)
{fos.write(i);}
else
{break;}
}
fos.flush();
Toast.makeText(this, "DB dump OK", Toast.LENGTH_LONG).show();
}
catch(Exception e)
{
e.printStackTrace();
Toast.makeText(this, "DB dump ERROR", Toast.LENGTH_LONG).show();
}
finally
{
try
{
fos.close();
fis.close();
}
catch(IOException ioe)
{}
}
}
Now call the bank () method within the OnCreate of your class.
How can you repair the following line:
File("/data/data/br.com.packagedoseuprojeto/databases/banco.db");
You should change the package to the address of your application. This is the path where you will find the banco.db file on your device, then you can open the file in the DB Browser for SQLite
It's a very complex way to go, but it has worked for me, if you can do something easier, I'll be happy to hear it too.
If you have any questions you can send me private msg.
Hugs.