Android Question Sqlite Database options

ALBRECHT

Active Member
Licensed User
Hello,

I like to get a suggest of method, regarding best practices for my App :

1/ i have an SQLITE db that contain general setting strings and language strings for its operation, and independent of user data. I systematicaly copy that DB from asset dir to Internal, so even after app updating, that strings are always uptodate.

2/ i have an other SQLLITE db that contain user settings tables and data tables completely dependent of the user. That DB is not killed or modify by app updating

So, is 2 databases the good way to admin this two different kind of data ?

Regards
Michel
 

AnandGupta

Expert
Licensed User
Longtime User
I do not see any problem here.
Many apps use more than one sqlite db as per their requirements.

Your connection string will determine which db is connected.

Regards,

Anand
 
Upvote 0

ALBRECHT

Active Member
Licensed User
Ok,

i was to be sure to correctly differentiate the data specific to the user (id, name, and all he makes with the app) from those of the app itself (like languages, settings ...).

and I told myself that it was possible to work with a single db, but so how ?

or the traitement in 2 separate db is the best way (especially to manage updates ...)
 
Upvote 0

AnandGupta

Expert
Licensed User
Longtime User
Two separate db are best way, as you are free with different tables and field names and manipulation of structure, as and when needed, IMHO.

Regards,

Anand
 
Upvote 0
Top