Android how to close db when query execute
<p>i have a websearch and db search ,this can be done at the same time , in db search am using db cursor for setting the result ,also for making search faster am open the db in OnCreate() and close it in onPause ,both the websearch and dbsearch running in separate async task ,when websearch result comes first am starting new activity,if db query is still executing am not able to close the db, how can close the db in this situation ,please help me</p>

<p>i get the following exeception </p>

<p>android.database.sqlite.SQLiteException: Unable to close due to unfinalised statements</p>
