Hi im trying to read sqlite file which is placed in assets/databases folder
i followed this link to read data from sqlite file
http://www.reigndesign.com/blog/using-your-own-sqlite-database-in-android-applications/
im getting error
no such table : while compiling
SELECT _id, name, address FROM
stores
Is there any permission i need to write in manifest to read sqlite file data?
Please let me know how i can solve this issue. Or else please give me any reference link to follow.
Thanks in advance
The way you’d want to do this is to make a new
DBManagerobject that creates the database in itsonCreatemethod–that way when theDatabaseHelperis first instantiated, the table will be created for you. Then you’d instantiate one and callgetReadableDatabase()on it to get a DB object which you can thenquery.This tutorial may help you more, it’s more succinct and up to date: http://developer.android.com/guide/topics/data/data-storage.html#db
After that, to set up the list view in a
ListActivity, you can callsetListAdapterand pass in aSimpleCursorAdapter. Here’s a tutorial on that: http://developer.android.com/guide/appendix/faq/commontasks.html#binding