I already discovered that there's not a way to bundle files within an .apk and also have them on /sdcard, the best choice to date being to download the big files upon first run. I found a tutorial saying how you can bundle an sqlite db using the apk after which copy it to ensure that it may be utilized with SQLiteDatabase (thus doubling the area needed, and never using /sdcard whatsoever).

http://developer.android.com/guide/subjects/data/data-storage.html#db states all databases Should be in /data/data/package_title/databases.

Is the fact that really so? It is possible to method to trick the framework into opening a database that's positioned on the /sdcard partition? It is possible to method to use another SQLite java wrapper/framework to gain access to such databases?

When the response to the above mentioned is 'No', the other options have i got? My information is perfectly symbolized inside a relational model, but is simply too large, plus, I wish to have the ability to update it with no need to re-install/upgrade the whole application.

Sure you are able to. The paperwork really are a little conflicting relating to this because they also state that no restrictions are enforced. I believe they ought to state that relative pathways will be to the above mentioned location and dbs you will find private. This is actually the code you would like:

File dbfile = new File("/sdcard/mydb.sqlite" ); 
SQLiteDatabase db = SQLiteDatabase.openOrCreateDatabase(dbfile, null);
System.out.println("Its open? "  + db.isOpen());

Just a concept:

  • you are able to put your database.db in to the assets folder.

  • in case your database.db file is bigger than 2Mb the machine is not able to compress it, which means you need other one options

  • you are able to relabel your database.db for instance database.jit or database.mp3 - which aren't compressed, than in the first cost you can relabel it to database.db