I have an SQLite database which I have to be constantly retrieving data from. Changes may be done to the data between each retrieval.
My goal is to maximize the app performance, so what is the fastest way to do this retrieving?
I can imagine 2:
-
constantly opening and closing new cursors
-
query all data at the beginning and store it in an ArrayList. When changing the data, change both SQLite DB and the ArrayList using
indexOf
.
Aucun commentaire:
Enregistrer un commentaire