What is best practice with SQLite and Android ?
- by PHP_Jedi
What is considered "best practice" when executing queries on a sql-lite db within an android app.
Is it safe to run inserts, deletes and select queries from an AsyncTask's doInBackground ? Or should I use the UI Thread ? I suppose that db queries can be "heavy" and should not use the UI thread as it can lock up the app - resulting in an ANR.
If I have several AsyncTasks, should they share a connection or should they open a connection each ?
Any best practices in this area on android?