Вам может пригодиться этот вопрос:
Как сделать резервную копию файла базы данных на SD-карте на Android?
@ skeniver говорит:
try {
File sd = Environment.getExternalStorageDirectory();
File data = Environment.getDataDirectory();
if (sd.canWrite()) {
String currentDBPath = "//data//{package name}//databases//{database name}";
String backupDBPath = "{database name}";
File currentDB = new File(data, currentDBPath);
File backupDB = new File(sd, backupDBPath);
if (currentDB.exists()) {
FileChannel src = new FileInputStream(currentDB).getChannel();
FileChannel dst = new FileOutputStream(backupDB).getChannel();
dst.transferFrom(src, 0, src.size());
src.close();
dst.close();
}
}
} catch (Exception e) {
}
с @Jakobud добавив, что вам нужно иметь
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
в вашем манифесте.